Explorar o código

* fix test for arm

git-svn-id: trunk@42538 -
florian %!s(int64=6) %!d(string=hai) anos
pai
achega
bdd4b6691e
Modificáronse 1 ficheiros con 18 adicións e 1 borrados
  1. 18 1
      tests/webtbs/tw11563.pp

+ 18 - 1
tests/webtbs/tw11563.pp

@@ -19,7 +19,7 @@ program ExecStack;
     ret: Byte;
 {$endif}
 {$ifdef cpuarm}
-    'add arm code to test stack execution'
+    ret: dword;
 {$endif}
 {$ifdef cpumips}
     ret: array[0..1] of longword;
@@ -77,6 +77,23 @@ program ExecStack;
     DoNothing;
 {$endif cpum68k}
 
+{$ifdef cpuarm}
+{$if defined(CPUTHUMB) or defined(CPUTHUMB2)}
+{$ifdef CPUARM_HAS_BX}
+    ret:=$4770;
+{$else}
+    ret:=$46f7;
+{$endif}
+{$else defined(CPUTHUMB) or defined(CPUTHUMB2)}
+    ret:=$e8bd8008;
+{$endif defined(CPUTHUMB) or defined(CPUTHUMB2)}
+{$ifdef ENDIAN_BIG}
+    ret:=SwapEndian(ret);
+{$endif ENDIAN_BIG}
+    DoNothing:=proc(@ret);
+    DoNothing;
+{$endif cpuarm}
+
   end;
 begin
   DoIt;