gallivm,ac: remove unused FUNC_ATTR_LAST enums
[mesa.git] / src / mapi / entry_x86_tls.h
index de918128eee576711794e9bc3ce0e470b8ae4dd4..545b5a3c786d90e6b4e0d3376f21ee8956068b4e 100644 (file)
@@ -1,6 +1,5 @@
 /*
  * Mesa 3-D graphics library
- * Version:  7.9
  *
  * Copyright (C) 2010 LunarG Inc.
  *
  */
 
 #include <string.h>
-#include "u_macros.h"
-
-#ifdef __linux__
-__asm__(".section .note.ABI-tag, \"a\"\n\t"
-        ".p2align 2\n\t"
-        ".long 1f - 0f\n\t"      /* name length */
-        ".long 3f - 2f\n\t"      /* data length */
-        ".long 1\n\t"            /* note length */
-        "0: .asciz \"GNU\"\n\t"  /* vendor name */
-        "1: .p2align 2\n\t"
-        "2: .long 0\n\t"         /* note data: the ABI tag */
-        ".long 2,4,20\n\t"       /* Minimum kernel version w/TLS */
-        "3: .p2align 2\n\t");    /* pad out section */
-#endif /* __linux__ */
+
+#ifdef HAVE_FUNC_ATTRIBUTE_VISIBILITY
+#define HIDDEN __attribute__((visibility("hidden")))
+#else
+#define HIDDEN
+#endif
 
 __asm__(".text");
 
@@ -86,8 +77,8 @@ __asm__(".text");
 extern unsigned long
 x86_current_tls();
 
-static char x86_entry_start[];
-static char x86_entry_end[];
+extern char x86_entry_start[] HIDDEN;
+extern char x86_entry_end[] HIDDEN;
 
 void
 entry_patch_public(void)
@@ -127,7 +118,7 @@ entry_generate(int slot)
       0xff, 0xa0, 0x34, 0x12, 0x00, 0x00, /* jmp *0x1234(%eax) */
       0x90, 0x90, 0x90, 0x90              /* nop's */
    };
-   void *code;
+   char *code;
    mapi_func entry;
 
    code = u_execmem_alloc(sizeof(code_templ));