mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-02-16 15:10:31 +01:00
glapi: Inline x86_64_current_tls().
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
This commit is contained in:
parent
d351bab9c5
commit
e34834f059
1 changed files with 2 additions and 8 deletions
|
|
@ -46,13 +46,6 @@ __asm__(".text\n"
|
|||
|
||||
#ifndef MAPI_MODE_BRIDGE
|
||||
|
||||
__asm__("x86_64_current_tls:\n\t"
|
||||
"movq " ENTRY_CURRENT_TABLE "@GOTTPOFF(%rip), %rax\n\t"
|
||||
"ret");
|
||||
|
||||
extern unsigned long
|
||||
x86_64_current_tls();
|
||||
|
||||
#include <string.h>
|
||||
#include "u_execmem.h"
|
||||
|
||||
|
|
@ -90,7 +83,8 @@ entry_generate(int slot)
|
|||
char *code;
|
||||
mapi_func entry;
|
||||
|
||||
addr = x86_64_current_tls();
|
||||
__asm__("movq " ENTRY_CURRENT_TABLE "@GOTTPOFF(%%rip), %0"
|
||||
: "=r" (addr));
|
||||
if ((addr >> 32) != 0xffffffff)
|
||||
return NULL;
|
||||
addr &= 0xffffffff;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue