/ thread.s (emx+gcc) -- Copyright (c) 1992-1993 by Eberhard Mattes

#if defined (__MT__)

        .globl  __thread
        .globl  __tid

        .text

        .align  2, 0x90

__thread:
        fs
        movl    12, %eax                / ptib2
        movl    0(%eax), %eax           / TID
        movl    __thread_tab(,%eax,4), %eax
        ret

        .align  2, 0x90

__tid:
        fs
        movl    12, %eax                / ptib2
        movl    0(%eax), %eax           / TID
        ret

#endif
