patch-src_libthread_FreeBSD-386-asm_s 852 B

12345678910111213141516171819202122232425262728293031323334353637
  1. $OpenBSD: patch-src_libthread_FreeBSD-386-asm_s,v 1.1 2013/03/21 22:26:27 sthen Exp $
  2. use movw with (16-bit) segment registers.
  3. --- src/libthread/FreeBSD-386-asm.s.orig Thu Mar 21 16:24:32 2013
  4. +++ src/libthread/FreeBSD-386-asm.s Thu Mar 21 16:24:50 2013
  5. @@ -9,10 +9,10 @@ _tas:
  6. getmcontext:
  7. movl 4(%esp), %eax
  8. - movl %fs, 8(%eax)
  9. - movl %es, 12(%eax)
  10. - movl %ds, 16(%eax)
  11. - movl %ss, 76(%eax)
  12. + movw %fs, 8(%eax)
  13. + movw %es, 12(%eax)
  14. + movw %ds, 16(%eax)
  15. + movw %ss, 76(%eax)
  16. movl %edi, 20(%eax)
  17. movl %esi, 24(%eax)
  18. movl %ebp, 28(%eax)
  19. @@ -34,10 +34,10 @@ getmcontext:
  20. setmcontext:
  21. movl 4(%esp), %eax
  22. - movl 8(%eax), %fs
  23. - movl 12(%eax), %es
  24. - movl 16(%eax), %ds
  25. - movl 76(%eax), %ss
  26. + movw 8(%eax), %fs
  27. + movw 12(%eax), %es
  28. + movw 16(%eax), %ds
  29. + movw 76(%eax), %ss
  30. movl 20(%eax), %edi
  31. movl 24(%eax), %esi
  32. movl 28(%eax), %ebp