Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
glslang
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
glslang
Commits
87a83d68
Commit
87a83d68
authored
Oct 05, 2016
by
Josh Gargus
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use pthread_mutex for global lock on Linux.
parent
9065ed83
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
ossource.cpp
glslang/OSDependent/Unix/ossource.cpp
+5
-4
No files found.
glslang/OSDependent/Unix/ossource.cpp
View file @
87a83d68
...
...
@@ -165,11 +165,12 @@ bool OS_FreeTLSIndex(OS_TLSIndex nIndex)
return
false
;
}
// TODO: non-windows: if we need these on linux, flesh them out
void
InitGlobalLock
()
{
}
void
GetGlobalLock
()
{
}
void
ReleaseGlobalLock
()
{
}
static
pthread_mutex_t
gMutex
;
void
InitGlobalLock
()
{
pthread_mutex_init
(
&
gMutex
,
NULL
);
}
void
GetGlobalLock
()
{
pthread_mutex_lock
(
&
gMutex
);
}
void
ReleaseGlobalLock
()
{
pthread_mutex_unlock
(
&
gMutex
);
}
// TODO: non-windows: if we need these on linux, flesh them out
void
*
OS_CreateThread
(
TThreadEntrypoint
/*entry*/
)
{
return
0
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment