[webkit-dev] LLInt alignment problem on ARM

2013-09-26 Thread Gabor Rapcsanyi

Hello!

I'm fighting with a strange LLInt alignment problem on ARM. As I see we 
put the LLInt code into .rodata section instead of .text.
Is there a specific reason why we are doing this? If there is not I 
would put them to the .text section.


Here is the objdump:

./Source/JavaScriptCore/.obj/release-shared/llint/LowLevelInterpreter.o: 
file format elf32-littlearm


Disassembly of section .rodata:

 _ZStL19piecewise_construct:
   0:   andeq   r0, r0, r0

0004 _ZStL13allocator_arg:
   4:   andeq   r0, r0, r0

0008 _ZStL6ignore:
...

0009 llint_begin:
   9:   e30b3eefmovwr3, #48879  ; 0xbeef
   d:   e34b3badmovtr3, #48045  ; 0xbbad
  11:   e583str r0, [r3]
  15:   e3a0mov r0, #0
  19:   e12fff30blx r0

001d llint_program_prologue:
  1d:   e1a0200emov r2, lr
  21:   e5852010str r2, [r5, #16]
  25:   e5951008ldr r1, [r5, #8]
...


The problem is that these traditional instructions are lying on odd 
adresses in the .rodata section.


Regards,
  Gabor

___
webkit-dev mailing list
webkit-dev@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-dev


Re: [webkit-dev] LLInt alignment problem on ARM

2013-09-26 Thread Oliver Hunt
I believe that there’s a mnemonic that forces alignment that we could (arguably 
should?) be using before these labels.

IIRC it’s something like .align N — if we aren’t doing this already we could 
make the lint assembler backend emit a .align 16 prior to each global symbol.

—Oliver

On Sep 26, 2013, at 1:09 AM, Gabor Rapcsanyi rga...@inf.u-szeged.hu wrote:

 Hello!
 
 I'm fighting with a strange LLInt alignment problem on ARM. As I see we put 
 the LLInt code into .rodata section instead of .text.
 Is there a specific reason why we are doing this? If there is not I would put 
 them to the .text section.
 
 Here is the objdump:
 
 ./Source/JavaScriptCore/.obj/release-shared/llint/LowLevelInterpreter.o: file 
 format elf32-littlearm
 
 Disassembly of section .rodata:
 
  _ZStL19piecewise_construct:
   0:   andeq   r0, r0, r0
 
 0004 _ZStL13allocator_arg:
   4:   andeq   r0, r0, r0
 
 0008 _ZStL6ignore:
...
 
 0009 llint_begin:
   9:   e30b3eefmovwr3, #48879  ; 0xbeef
   d:   e34b3badmovtr3, #48045  ; 0xbbad
  11:   e583str r0, [r3]
  15:   e3a0mov r0, #0
  19:   e12fff30blx r0
 
 001d llint_program_prologue:
  1d:   e1a0200emov r2, lr
  21:   e5852010str r2, [r5, #16]
  25:   e5951008ldr r1, [r5, #8]
 ...
 
 
 The problem is that these traditional instructions are lying on odd adresses 
 in the .rodata section.
 
 Regards,
  Gabor
 
 ___
 webkit-dev mailing list
 webkit-dev@lists.webkit.org
 https://lists.webkit.org/mailman/listinfo/webkit-dev

___
webkit-dev mailing list
webkit-dev@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-dev


Re: [webkit-dev] LLInt alignment problem on ARM

2013-09-26 Thread Michael Saboff
I’m wondering if the alignment is the traditional ARM vs Thumb 2.  The movw 
after lint_begin with hex  0xe30b3eef is a Thumb 2 instruction.

- Michael

On Sep 26, 2013, at 9:24 AM, Oliver Hunt oli...@apple.com wrote:

 I believe that there’s a mnemonic that forces alignment that we could 
 (arguably should?) be using before these labels.
 
 IIRC it’s something like .align N — if we aren’t doing this already we could 
 make the lint assembler backend emit a .align 16 prior to each global symbol.
 
 —Oliver
 
 On Sep 26, 2013, at 1:09 AM, Gabor Rapcsanyi rga...@inf.u-szeged.hu wrote:
 
 Hello!
 
 I'm fighting with a strange LLInt alignment problem on ARM. As I see we put 
 the LLInt code into .rodata section instead of .text.
 Is there a specific reason why we are doing this? If there is not I would 
 put them to the .text section.
 
 Here is the objdump:
 
 ./Source/JavaScriptCore/.obj/release-shared/llint/LowLevelInterpreter.o: 
 file format elf32-littlearm
 
 Disassembly of section .rodata:
 
  _ZStL19piecewise_construct:
  0:   andeq   r0, r0, r0
 
 0004 _ZStL13allocator_arg:
  4:   andeq   r0, r0, r0
 
 0008 _ZStL6ignore:
   ...
 
 0009 llint_begin:
  9:   e30b3eefmovwr3, #48879  ; 0xbeef
  d:   e34b3badmovtr3, #48045  ; 0xbbad
 11:   e583str r0, [r3]
 15:   e3a0mov r0, #0
 19:   e12fff30blx r0
 
 001d llint_program_prologue:
 1d:   e1a0200emov r2, lr
 21:   e5852010str r2, [r5, #16]
 25:   e5951008ldr r1, [r5, #8]
 ...
 
 
 The problem is that these traditional instructions are lying on odd adresses 
 in the .rodata section.
 
 Regards,
 Gabor
 
 ___
 webkit-dev mailing list
 webkit-dev@lists.webkit.org
 https://lists.webkit.org/mailman/listinfo/webkit-dev
 
 ___
 webkit-dev mailing list
 webkit-dev@lists.webkit.org
 https://lists.webkit.org/mailman/listinfo/webkit-dev

___
webkit-dev mailing list
webkit-dev@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-dev