I just recently ported PhysX to build on Emscripten after the removal of syscalls. You see there that there's posix-specific paths that can be used instead, which Emscripten likes better. Instead of syscall(SYS_gettid) , you can call pthread_self(), and Emscripten does not have a concept of thread affinity, so that can be commented out (behave like the Apple/Qnx path).
2015-08-28 2:10 GMT+03:00 Alon Zakai <[email protected]>: > There might be more standard ways to do that, I believe pthreads lets you > access the current thread's id, etc. Using those should work (to the extent > that we support those features - we don't have a way to support affinity > AFAIK). > > On Thu, Aug 27, 2015 at 2:34 PM, Robert Goulet <[email protected] > > wrote: > >> I'm not sure this is really important, it's used by PhysX 3.3.3 to >> retrieve thread id and manage affinity. I don't think this will prevent the >> library from running properly (perhaps slightly less optimal), so for now I >> would guess it's not really needed. But it's good to hear that the change >> was intended on Emscripten side. :) >> >> The calls refer to these ids: >> >> syscall(__NR_gettid); >> syscall(__NR_sched_getaffinity, ...); >> >> Thanks for the quick reply! >> >> >> On Thursday, August 27, 2015 at 4:43:36 PM UTC-4, Alon Zakai wrote: >>> >>> Yes, we don't support direct syscalls by the user any more. Those are >>> dynamic, and would require us to link in all the possible syscall targets. >>> We avoid that code size increase by linking in syscalls statically. >>> >>> Do you actually need syscall() to work? We might be able to add an >>> option for that. >>> >>> On Thu, Aug 27, 2015 at 1:35 PM, Robert Goulet <[email protected]> >>> wrote: >>> >>>> Looks like the function syscall is no longer available when using >>>> Emscripten 1.34.6? >>>> >>>> It used to be found in Emscripten 1.34.1, is this intended? >>>> >>>> Thanks! >>>> >>>> -- >>>> You received this message because you are subscribed to the Google >>>> Groups "emscripten-discuss" group. >>>> To unsubscribe from this group and stop receiving emails from it, send >>>> an email to [email protected]. >>>> For more options, visit https://groups.google.com/d/optout. >>>> >>> >>> -- >> You received this message because you are subscribed to the Google Groups >> "emscripten-discuss" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected]. >> For more options, visit https://groups.google.com/d/optout. >> > > -- > You received this message because you are subscribed to the Google Groups > "emscripten-discuss" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "emscripten-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
