Kaydet (Commit) dbd0fa72 authored tarafından Tor Lillqvist's avatar Tor Lillqvist

Use // consistently for comments in the iOS assembly sources

Change-Id: I60bbf6c309130bbf868745b3ba6fc1c0729d850a
üst 267e507f
...@@ -34,11 +34,11 @@ printf (".text\n"); ...@@ -34,11 +34,11 @@ printf (".text\n");
printf ("#ifdef __arm\n"); printf ("#ifdef __arm\n");
printf ("\n"); printf ("\n");
printf ("@ Each codeSnippetX function stores pc into ip and branches to _privateSnippetExecutor\n"); printf ("// Each codeSnippetX function stores pc into ip and branches to _privateSnippetExecutor\n");
printf ("@ The branch instruction is followed by two longs (that ip thus points to):\n"); printf ("// The branch instruction is followed by two longs (that ip thus points to):\n");
printf ("@ - the function index, as such and with the 0x80000000 bit set\n"); printf ("// - the function index, as such and with the 0x80000000 bit set\n");
printf ("@ (to indicate a hidden parameter for returning large values)\n"); printf ("// (to indicate a hidden parameter for returning large values)\n");
printf ("@ - the vtable offset\n"); printf ("// - the vtable offset\n");
printf ("\n"); printf ("\n");
printf ("\t.align 4\n"); printf ("\t.align 4\n");
......
/* // This file is part of the LibreOffice project.
* This file is part of the LibreOffice project. //
* // This Source Code Form is subject to the terms of the Mozilla Public
* This Source Code Form is subject to the terms of the Mozilla Public // License, v. 2.0. If a copy of the MPL was not distributed with this
* License, v. 2.0. If a copy of the MPL was not distributed with this // file, You can obtain one at http://mozilla.org/MPL/2.0/.
* file, You can obtain one at http://mozilla.org/MPL/2.0/. //
* // This file incorporates work covered by the following license notice:
* This file incorporates work covered by the following license notice: //
* // Licensed to the Apache Software Foundation (ASF) under one or more
* Licensed to the Apache Software Foundation (ASF) under one or more // contributor license agreements. See the NOTICE file distributed
* contributor license agreements. See the NOTICE file distributed // with this work for additional information regarding copyright
* with this work for additional information regarding copyright // ownership. The ASF licenses this file to you under the Apache
* ownership. The ASF licenses this file to you under the Apache // License, Version 2.0 (the "License"); you may not use this file
* License, Version 2.0 (the "License"); you may not use this file // except in compliance with the License. You may obtain a copy of
* except in compliance with the License. You may obtain a copy of // the License at http://www.apache.org/licenses/LICENSE-2.0 .
* the License at http://www.apache.org/licenses/LICENSE-2.0 . //
*/
#include "codesnippets.S" #include "codesnippets.S"
#ifdef __arm #ifdef __arm
@ ARM support code for LibreOffice C++/UNO bridging // ARM support code for LibreOffice C++/UNO bridging
@ //
@ Written by Peter Naulls <peter@chocky.org> // Written by Peter Naulls <peter@chocky.org>
@ Modified by Caolan McNamara <caolanm@redhat.com> // Modified by Caolan McNamara <caolanm@redhat.com>
@ Fixed by Michael Casadevall <mcasadevall@kubuntu.org> // Fixed by Michael Casadevall <mcasadevall@kubuntu.org>
@ Modified for iOS by Tor Lillqvist <tml@iki.fi> // Modified for iOS by Tor Lillqvist <tml@iki.fi>
.text .text
.align 4 .align 4
_privateSnippetExecutor: _privateSnippetExecutor:
stmfd sp!, {r0-r3} @ follow other parameters on stack stmfd sp!, {r0-r3} // follow other parameters on stack
mov r0, ip @ r0 points to functionoffset/vtable mov r0, ip // r0 points to functionoffset/vtable
mov r1, sp @ r1 points to this and params mov r1, sp // r1 points to this and params
@ (see cpp2uno.cxx:codeSnippet()) // (see cpp2uno.cxx:codeSnippet())
stmfd sp!, {r4,lr} @ save return address stmfd sp!, {r4,lr} // save return address
@ (r4 pushed to preserve stack alignment) // (r4 pushed to preserve stack alignment)
bl _cpp_vtable_call bl _cpp_vtable_call
add sp, sp, #4 @ no need to restore r4 (we didn't touch it) add sp, sp, #4 // no need to restore r4 (we didn't touch it)
ldr pc, [sp], #20 @ return, discarding function arguments ldr pc, [sp], #20 // return, discarding function arguments
#else #else
.text .text
...@@ -48,17 +47,17 @@ _privateSnippetExecutor: ...@@ -48,17 +47,17 @@ _privateSnippetExecutor:
_privateSnippetExecutorGeneral: _privateSnippetExecutorGeneral:
LFBg: LFBg:
movl %esp,%ecx movl %esp,%ecx
pushl %ebp # proper stack frame needed for exception handling pushl %ebp // proper stack frame needed for exception handling
LCFIg0: LCFIg0:
movl %esp,%ebp movl %esp,%ebp
LCFIg1: LCFIg1:
subl $0x8,%esp # padding + 32bit returnValue subl $0x8,%esp // padding + 32bit returnValue
pushl %esp # 32bit &returnValue pushl %esp // 32bit &returnValue
pushl %ecx # 32bit pCallStack pushl %ecx // 32bit pCallStack
pushl %edx # 32bit nVtableOffset pushl %edx // 32bit nVtableOffset
pushl %eax # 32bit nFunctionIndex pushl %eax // 32bit nFunctionIndex
call L_cpp_vtable_call$stub call L_cpp_vtable_call$stub
movl 16(%esp),%eax # 32bit returnValue movl 16(%esp),%eax // 32bit returnValue
leave leave
ret ret
LFEg: LFEg:
...@@ -68,15 +67,15 @@ LFEg: ...@@ -68,15 +67,15 @@ LFEg:
_privateSnippetExecutorVoid: _privateSnippetExecutorVoid:
LFBv: LFBv:
movl %esp,%ecx movl %esp,%ecx
pushl %ebp # proper stack frame needed for exception handling pushl %ebp // proper stack frame needed for exception handling
LCFIv0: LCFIv0:
movl %esp,%ebp movl %esp,%ebp
LCFIv1: LCFIv1:
sub $8,%esp # padding sub $8,%esp // padding
pushl $0 # 32bit null pointer (returnValue not used) pushl $0 // 32bit null pointer (returnValue not used)
pushl %ecx # 32bit pCallStack pushl %ecx // 32bit pCallStack
pushl %edx # 32bit nVtableOffset pushl %edx // 32bit nVtableOffset
pushl %eax # 32bit nFunctionIndex pushl %eax // 32bit nFunctionIndex
call L_cpp_vtable_call$stub call L_cpp_vtable_call$stub
leave leave
ret ret
...@@ -87,18 +86,18 @@ LFEv: ...@@ -87,18 +86,18 @@ LFEv:
_privateSnippetExecutorHyper: _privateSnippetExecutorHyper:
LFBh: LFBh:
movl %esp,%ecx movl %esp,%ecx
pushl %ebp # proper stack frame needed for exception handling pushl %ebp // proper stack frame needed for exception handling
LCFIh0: LCFIh0:
movl %esp,%ebp movl %esp,%ebp
LCFIh1: LCFIh1:
subl $0x8,%esp # 64bit returnValue subl $0x8,%esp // 64bit returnValue
pushl %esp # 32bit &returnValue pushl %esp // 32bit &returnValue
pushl %ecx # 32bit pCallStack pushl %ecx // 32bit pCallStack
pushl %edx # 32bit nVtableOffset pushl %edx // 32bit nVtableOffset
pushl %eax # 32bit nFunctionIndex pushl %eax // 32bit nFunctionIndex
call L_cpp_vtable_call$stub call L_cpp_vtable_call$stub
movl 16(%esp),%eax # 64bit returnValue, lower half movl 16(%esp),%eax // 64bit returnValue, lower half
movl 20(%esp),%edx # 64bit returnValue, upper half movl 20(%esp),%edx // 64bit returnValue, upper half
leave leave
ret ret
LFEh: LFEh:
...@@ -108,17 +107,17 @@ LFEh: ...@@ -108,17 +107,17 @@ LFEh:
_privateSnippetExecutorFloat: _privateSnippetExecutorFloat:
LFBf: LFBf:
movl %esp,%ecx movl %esp,%ecx
pushl %ebp # proper stack frame needed for exception handling pushl %ebp // proper stack frame needed for exception handling
LCFIf0: LCFIf0:
movl %esp,%ebp movl %esp,%ebp
LCFIf1: LCFIf1:
subl $0x8,%esp # padding + 32bit returnValue subl $0x8,%esp // padding + 32bit returnValue
pushl %esp # 32bit &returnValue pushl %esp // 32bit &returnValue
pushl %ecx # 32bit pCallStack pushl %ecx // 32bit pCallStack
pushl %edx # 32bit nVtableOffset pushl %edx // 32bit nVtableOffset
pushl %eax # 32bit nFunctionIndex pushl %eax // 32bit nFunctionIndex
call L_cpp_vtable_call$stub call L_cpp_vtable_call$stub
flds 16(%esp) # 32bit returnValue flds 16(%esp) // 32bit returnValue
leave leave
ret ret
LFEf: LFEf:
...@@ -128,17 +127,17 @@ LFEf: ...@@ -128,17 +127,17 @@ LFEf:
_privateSnippetExecutorDouble: _privateSnippetExecutorDouble:
LFBd: LFBd:
movl %esp,%ecx movl %esp,%ecx
pushl %ebp # proper stack frame needed for exception handling pushl %ebp // proper stack frame needed for exception handling
LCFId0: LCFId0:
movl %esp,%ebp movl %esp,%ebp
LCFId1: LCFId1:
subl $0x8,%esp # 64bit returnValue subl $0x8,%esp // 64bit returnValue
pushl %esp # 32bit &returnValue pushl %esp // 32bit &returnValue
pushl %ecx # 32bit pCallStack pushl %ecx // 32bit pCallStack
pushl %edx # 32bit nVtableOffset pushl %edx // 32bit nVtableOffset
pushl %eax # 32bit nFunctionIndex pushl %eax // 32bit nFunctionIndex
call L_cpp_vtable_call$stub call L_cpp_vtable_call$stub
fldl 16(%esp) # 64bit returnValue fldl 16(%esp) // 64bit returnValue
leave leave
ret ret
LFEd: LFEd:
...@@ -148,17 +147,17 @@ LFEd: ...@@ -148,17 +147,17 @@ LFEd:
_privateSnippetExecutorClass: _privateSnippetExecutorClass:
LFBc: LFBc:
movl %esp,%ecx movl %esp,%ecx
pushl %ebp # proper stack frame needed for exception handling pushl %ebp // proper stack frame needed for exception handling
LCFIc0: LCFIc0:
movl %esp,%ebp movl %esp,%ebp
LCFIc1: LCFIc1:
subl $0x8,%esp # padding + 32bit returnValue subl $0x8,%esp // padding + 32bit returnValue
pushl %esp # 32bit &returnValue pushl %esp // 32bit &returnValue
pushl %ecx # 32bit pCallStack pushl %ecx // 32bit pCallStack
pushl %edx # 32bit nVtableOffset pushl %edx // 32bit nVtableOffset
pushl %eax # 32bit nFunctionIndex pushl %eax // 32bit nFunctionIndex
call L_cpp_vtable_call$stub call L_cpp_vtable_call$stub
movl 16(%esp),%eax # 32bit returnValue movl 16(%esp),%eax // 32bit returnValue
leave leave
ret $4 ret $4
LFEc: LFEc:
...@@ -167,155 +166,155 @@ LFEc: ...@@ -167,155 +166,155 @@ LFEc:
.section __TEXT,__eh_frame,coalesced,no_toc+strip_static_syms+live_support .section __TEXT,__eh_frame,coalesced,no_toc+strip_static_syms+live_support
EH_frame1: EH_frame1:
.set L$set$frame1,LECIE1-LSCIE1 .set L$set$frame1,LECIE1-LSCIE1
.long L$set$frame1 # length .long L$set$frame1 // length
LSCIE1: LSCIE1:
.long 0 # CIE_ID .long 0 // CIE_ID
.byte 1 # version .byte 1 // version
.ascii "zPR\0" # augmentation .ascii "zPR\0" // augmentation
.byte 1 # code_alignment_factor (.uleb128 1) .byte 1 // code_alignment_factor (.uleb128 1)
.byte 0x7c # data_alignment_factor (.sleb128 -4) .byte 0x7c // data_alignment_factor (.sleb128 -4)
.byte 8 # return_address_register .byte 8 // return_address_register
.byte 0x6 # augmentation size 7: .byte 0x6 // augmentation size 7:
.byte 0x9b # ??? .byte 0x9b // ???
.long L___gxx_personality_v0$non_lazy_ptr-. .long L___gxx_personality_v0$non_lazy_ptr-.
.byte 0x10 .byte 0x10
# initial_instructions: // initial_instructions:
.byte 0x0C # DW_CFA_def_cfa %esp, 4 .byte 0x0C // DW_CFA_def_cfa %esp, 4
.byte 5 .byte 5
.byte 4 .byte 4
.byte 0x88 # DW_CFA_offset ret, 1 .byte 0x88 // DW_CFA_offset ret, 1
.byte 1 .byte 1
.align 2 .align 2
LECIE1: LECIE1:
_privateSnippetExecutorGeneral.eh: _privateSnippetExecutorGeneral.eh:
LSFDEg: LSFDEg:
.set L$set$g1,LEFDEg-LASFDEg .set L$set$g1,LEFDEg-LASFDEg
.long L$set$g1 # length .long L$set$g1 // length
LASFDEg: LASFDEg:
.long LASFDEg-EH_frame1 # CIE_pointer .long LASFDEg-EH_frame1 // CIE_pointer
.long LFBg-. # initial_location .long LFBg-. // initial_location
.long LFEg-LFBg # address_range .long LFEg-LFBg // address_range
.byte 0 # augmentation size 0 .byte 0 // augmentation size 0
# instructions: // instructions:
.byte 0x04 # DW_CFA_advance_loc4 .byte 0x04 // DW_CFA_advance_loc4
.long LCFIg0-LFBg .long LCFIg0-LFBg
.byte 0x0E # DW_CFA_def_cfa_offset 8 .byte 0x0E // DW_CFA_def_cfa_offset 8
.byte 8 .byte 8
.byte 0x84 # DW_CFA_offset %ebp, 2 .byte 0x84 // DW_CFA_offset %ebp, 2
.byte 2 .byte 2
.byte 0x04 # DW_CFA_advance_loc4 .byte 0x04 // DW_CFA_advance_loc4
.long LCFIg1-LCFIg0 .long LCFIg1-LCFIg0
.byte 0x0D # DW_CFA_def_cfa_register %ebp .byte 0x0D // DW_CFA_def_cfa_register %ebp
.byte 4 .byte 4
.align 2 .align 2
LEFDEg: LEFDEg:
_privateSnippetExecutorVoid.eh: _privateSnippetExecutorVoid.eh:
LSFDEv: LSFDEv:
.set L$set$v1,LEFDEv-LASFDEv .set L$set$v1,LEFDEv-LASFDEv
.long L$set$v1 # length .long L$set$v1 // length
LASFDEv: LASFDEv:
.long LASFDEv-EH_frame1 # CIE_pointer .long LASFDEv-EH_frame1 // CIE_pointer
.long LFBv-. # initial_location .long LFBv-. // initial_location
.long LFEv-LFBv # address_range .long LFEv-LFBv // address_range
.byte 0 # augmentation size 0 .byte 0 // augmentation size 0
# instructions: // instructions:
.byte 0x04 # DW_CFA_advance_loc4 .byte 0x04 // DW_CFA_advance_loc4
.long LCFIv0-LFBv .long LCFIv0-LFBv
.byte 0x0E # DW_CFA_def_cfa_offset 8 .byte 0x0E // DW_CFA_def_cfa_offset 8
.byte 8 .byte 8
.byte 0x84 # DW_CFA_offset %ebp, 2 .byte 0x84 // DW_CFA_offset %ebp, 2
.byte 2 .byte 2
.byte 0x04 # DW_CFA_advance_loc4 .byte 0x04 // DW_CFA_advance_loc4
.long LCFIv1-LCFIv0 .long LCFIv1-LCFIv0
.byte 0x0D # DW_CFA_def_cfa_register %ebp .byte 0x0D // DW_CFA_def_cfa_register %ebp
.byte 4 .byte 4
.align 2 .align 2
LEFDEv: LEFDEv:
_privateSnippetExecutorHyper.eh: _privateSnippetExecutorHyper.eh:
LSFDEh: LSFDEh:
.set L$set$h1,LEFDEh-LASFDEh .set L$set$h1,LEFDEh-LASFDEh
.long L$set$h1 # length .long L$set$h1 // length
LASFDEh: LASFDEh:
.long LASFDEh-EH_frame1 # CIE_pointer .long LASFDEh-EH_frame1 // CIE_pointer
.long LFBh-. # initial_location .long LFBh-. // initial_location
.long LFEh-LFBh # address_range .long LFEh-LFBh // address_range
.byte 0 # augmentation size 0 .byte 0 // augmentation size 0
# instructions: // instructions:
.byte 0x04 # DW_CFA_advance_loc4 .byte 0x04 // DW_CFA_advance_loc4
.long LCFIh0-LFBh .long LCFIh0-LFBh
.byte 0x0E # DW_CFA_def_cfa_offset 8 .byte 0x0E // DW_CFA_def_cfa_offset 8
.byte 8 .byte 8
.byte 0x84 # DW_CFA_offset %ebp, 2 .byte 0x84 // DW_CFA_offset %ebp, 2
.byte 2 .byte 2
.byte 0x04 # DW_CFA_advance_loc4 .byte 0x04 // DW_CFA_advance_loc4
.long LCFIh1-LCFIh0 .long LCFIh1-LCFIh0
.byte 0x0D # DW_CFA_def_cfa_register %ebp .byte 0x0D // DW_CFA_def_cfa_register %ebp
.byte 4 .byte 4
.align 2 .align 2
LEFDEh: LEFDEh:
_privateSnippetExecutorFloat.eh: _privateSnippetExecutorFloat.eh:
LSFDEf: LSFDEf:
.set L$set$f1,LEFDEf-LASFDEf .set L$set$f1,LEFDEf-LASFDEf
.long L$set$f1 # length .long L$set$f1 // length
LASFDEf: LASFDEf:
.long LASFDEf-EH_frame1 # CIE_pointer .long LASFDEf-EH_frame1 // CIE_pointer
.long LFBf-. # initial_location .long LFBf-. // initial_location
.long LFEf-LFBf # address_range .long LFEf-LFBf // address_range
.byte 0 # augmentation size 0 .byte 0 // augmentation size 0
# instructions: // instructions:
.byte 0x04 # DW_CFA_advance_loc4 .byte 0x04 // DW_CFA_advance_loc4
.long LCFIf0-LFBf .long LCFIf0-LFBf
.byte 0x0E # DW_CFA_def_cfa_offset 8 .byte 0x0E // DW_CFA_def_cfa_offset 8
.byte 8 .byte 8
.byte 0x84 # DW_CFA_offset %ebp, 2 .byte 0x84 // DW_CFA_offset %ebp, 2
.byte 2 .byte 2
.byte 0x04 # DW_CFA_advance_loc4 .byte 0x04 // DW_CFA_advance_loc4
.long LCFIf1-LCFIf0 .long LCFIf1-LCFIf0
.byte 0x0D # DW_CFA_def_cfa_register %ebp .byte 0x0D // DW_CFA_def_cfa_register %ebp
.byte 4 .byte 4
.align 2 .align 2
LEFDEf: LEFDEf:
_privateSnippetExecutorDouble.eh: _privateSnippetExecutorDouble.eh:
LSFDEd: LSFDEd:
.set L$set$d1,LEFDEd-LASFDEd .set L$set$d1,LEFDEd-LASFDEd
.long L$set$d1 # length .long L$set$d1 // length
LASFDEd: LASFDEd:
.long LASFDEd-EH_frame1 # CIE_pointer .long LASFDEd-EH_frame1 // CIE_pointer
.long LFBd-. # initial_location .long LFBd-. // initial_location
.long LFEd-LFBd # address_range .long LFEd-LFBd // address_range
.byte 0 # augmentation size 0 .byte 0 // augmentation size 0
# instructions: // instructions:
.byte 0x04 # DW_CFA_advance_loc4 .byte 0x04 // DW_CFA_advance_loc4
.long LCFId0-LFBd .long LCFId0-LFBd
.byte 0x0E # DW_CFA_def_cfa_offset 8 .byte 0x0E // DW_CFA_def_cfa_offset 8
.byte 8 .byte 8
.byte 0x84 # DW_CFA_offset %ebp, 2 .byte 0x84 // DW_CFA_offset %ebp, 2
.byte 2 .byte 2
.byte 0x04 # DW_CFA_advance_loc4 .byte 0x04 // DW_CFA_advance_loc4
.long LCFId1-LCFId0 .long LCFId1-LCFId0
.byte 0x0D # DW_CFA_def_cfa_register %ebp .byte 0x0D // DW_CFA_def_cfa_register %ebp
.byte 4 .byte 4
.align 2 .align 2
LEFDEd: LEFDEd:
_privateSnippetExecutorClass.eh: _privateSnippetExecutorClass.eh:
LSFDEc: LSFDEc:
.set L$set$c1,LEFDEc-LASFDEc .set L$set$c1,LEFDEc-LASFDEc
.long L$set$c1 # length .long L$set$c1 // length
LASFDEc: LASFDEc:
.long LASFDEc-EH_frame1 # CIE_pointer .long LASFDEc-EH_frame1 // CIE_pointer
.long LFBc-. # initial_location .long LFBc-. // initial_location
.long LFEc-LFBc # address_range .long LFEc-LFBc // address_range
.byte 0 # augmentation size 0 .byte 0 // augmentation size 0
# instructions: // instructions:
.byte 0x04 # DW_CFA_advance_loc4 .byte 0x04 // DW_CFA_advance_loc4
.long LCFIc0-LFBc .long LCFIc0-LFBc
.byte 0x0E # DW_CFA_def_cfa_offset 8 .byte 0x0E // DW_CFA_def_cfa_offset 8
.byte 8 .byte 8
.byte 0x84 # DW_CFA_offset %ebp, 2 .byte 0x84 // DW_CFA_offset %ebp, 2
.byte 2 .byte 2
.byte 0x04 # DW_CFA_advance_loc4 .byte 0x04 // DW_CFA_advance_loc4
.long LCFIc1-LCFIc0 .long LCFIc1-LCFIc0
.byte 0x0D # DW_CFA_def_cfa_register %ebp .byte 0x0D // DW_CFA_def_cfa_register %ebp
.byte 4 .byte 4
.align 2 .align 2
LEFDEc: LEFDEc:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment