aboutsummaryrefslogtreecommitdiff
path: root/test/CodeGen/JS
diff options
context:
space:
mode:
Diffstat (limited to 'test/CodeGen/JS')
-rw-r--r--test/CodeGen/JS/aliases.ll7
-rw-r--r--test/CodeGen/JS/allocamanager.ll3
-rw-r--r--test/CodeGen/JS/asm.ll5
-rw-r--r--test/CodeGen/JS/basics.ll5
-rw-r--r--test/CodeGen/JS/dead-prototypes.ll5
-rw-r--r--test/CodeGen/JS/expect-intrinsics.ll6
-rw-r--r--test/CodeGen/JS/ffis-f32.ll5
-rw-r--r--test/CodeGen/JS/ffis.ll5
-rw-r--r--test/CodeGen/JS/getelementptr.ll3
-rw-r--r--test/CodeGen/JS/global-alias.ll5
-rw-r--r--test/CodeGen/JS/globals.ll5
-rw-r--r--test/CodeGen/JS/invariant-intrinsics.ll5
-rw-r--r--test/CodeGen/JS/lifetime-intrinsics.ll5
-rw-r--r--test/CodeGen/JS/mem-intrinsics.ll5
-rw-r--r--test/CodeGen/JS/phi.ll5
15 files changed, 53 insertions, 21 deletions
diff --git a/test/CodeGen/JS/aliases.ll b/test/CodeGen/JS/aliases.ll
index 7818f0de8b..112cbd6764 100644
--- a/test/CodeGen/JS/aliases.ll
+++ b/test/CodeGen/JS/aliases.ll
@@ -1,10 +1,5 @@
-; RUN: llc -march=js -o - < %s | FileCheck %s
+; RUN: llc < %s | FileCheck %s
-; ModuleID = 'test/CodeGen/JS/aliases.ll'
-target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
-target triple = "asmjs-unknown-emscripten"
-
-; ModuleID = 'tests/hello_world.bc'
target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
target triple = "asmjs-unknown-emscripten"
diff --git a/test/CodeGen/JS/allocamanager.ll b/test/CodeGen/JS/allocamanager.ll
index c2f7c5f53d..2b2d7c57fb 100644
--- a/test/CodeGen/JS/allocamanager.ll
+++ b/test/CodeGen/JS/allocamanager.ll
@@ -1,10 +1,9 @@
-; RUN: llc -march=js -o - < %s | FileCheck %s
+; RUN: llc < %s | FileCheck %s
; Basic AllocaManager feature test. Eliminate user variable cupcake in favor of
; user variable muffin, and combine all the vararg buffers. And align the stack
; pointer.
-; ModuleID = 'test/CodeGen/JS/allocamanager.ll'
target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
target triple = "asmjs-unknown-emscripten"
diff --git a/test/CodeGen/JS/asm.ll b/test/CodeGen/JS/asm.ll
index 41a30431da..c3099e3239 100644
--- a/test/CodeGen/JS/asm.ll
+++ b/test/CodeGen/JS/asm.ll
@@ -1,4 +1,4 @@
-; RUN: not llc -march=js < %s
+; RUN: not llc < %s
; Inline asm isn't supported (yet?). llc should report an error when it
; encounters inline asm.
@@ -7,6 +7,9 @@
; work, but code that uses such things most likely isn't portable anyway, and
; there are usually much better alternatives.
+target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
+target triple = "asmjs-unknown-emscripten"
+
define void @foo() {
call void asm "", ""()
ret void
diff --git a/test/CodeGen/JS/basics.ll b/test/CodeGen/JS/basics.ll
index c24a92487f..573680f810 100644
--- a/test/CodeGen/JS/basics.ll
+++ b/test/CodeGen/JS/basics.ll
@@ -1,4 +1,7 @@
-; RUN: llc < %s -march=js -o - | FileCheck %s
+; RUN: llc < %s | FileCheck %s
+
+target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
+target triple = "asmjs-unknown-emscripten"
; CHECK: function _simple_integer_math(
; CHECK: [[VAL_A:\$[a-z]+]] = [[VAL_A]]|0;
diff --git a/test/CodeGen/JS/dead-prototypes.ll b/test/CodeGen/JS/dead-prototypes.ll
index 2a723ed61e..6d57b5a791 100644
--- a/test/CodeGen/JS/dead-prototypes.ll
+++ b/test/CodeGen/JS/dead-prototypes.ll
@@ -1,7 +1,10 @@
-; RUN: llc -march=js < %s | not grep printf
+; RUN: llc < %s | not grep printf
; llc shouldn't emit any code or bookkeeping for unused declarations.
+target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
+target triple = "asmjs-unknown-emscripten"
+
define void @foo() {
ret void
}
diff --git a/test/CodeGen/JS/expect-intrinsics.ll b/test/CodeGen/JS/expect-intrinsics.ll
index b061f52967..6d2cba4592 100644
--- a/test/CodeGen/JS/expect-intrinsics.ll
+++ b/test/CodeGen/JS/expect-intrinsics.ll
@@ -1,9 +1,13 @@
-; RUN: llc -march=js < %s | FileCheck %s
+; RUN: llc < %s | FileCheck %s
; Handle the llvm.expect intrinsic.
+target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
+target triple = "asmjs-unknown-emscripten"
+
; CHECK: $expval = $x;
; CHECK: $tobool = ($expval|0)!=(0);
+
define void @foo(i32 %x) {
entry:
%expval = call i32 @llvm.expect.i32(i32 %x, i32 0)
diff --git a/test/CodeGen/JS/ffis-f32.ll b/test/CodeGen/JS/ffis-f32.ll
index 39d3c65b6c..63b8e9a5ff 100644
--- a/test/CodeGen/JS/ffis-f32.ll
+++ b/test/CodeGen/JS/ffis-f32.ll
@@ -1,7 +1,10 @@
-; RUN: llc -emscripten-precise-f32 -march=js < %s | FileCheck %s
+; RUN: llc -emscripten-precise-f32 < %s | FileCheck %s
; Use proper types to ffi calls, with float32
+target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
+target triple = "asmjs-unknown-emscripten"
+
; CHECK: (+Math_sqrt(+1));
; CHECK-NEXT: (Math_fround(Math_sqrt(Math_fround(+1))));
; CHECK-NEXT: (+Math_sqrt((+$d)));
diff --git a/test/CodeGen/JS/ffis.ll b/test/CodeGen/JS/ffis.ll
index 9e3de7bad1..d5b8e334e7 100644
--- a/test/CodeGen/JS/ffis.ll
+++ b/test/CodeGen/JS/ffis.ll
@@ -1,7 +1,10 @@
-; RUN: llc -march=js < %s | FileCheck %s
+; RUN: llc < %s | FileCheck %s
; Use proper types to ffi calls, no float32
+target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
+target triple = "asmjs-unknown-emscripten"
+
; CHECK: (+Math_sqrt(+1));
; CHECK-NEXT: (+Math_sqrt(+1));
; CHECK-NEXT: (+Math_sqrt((+$d)));
diff --git a/test/CodeGen/JS/getelementptr.ll b/test/CodeGen/JS/getelementptr.ll
index 2dbb868b94..ec56cbe207 100644
--- a/test/CodeGen/JS/getelementptr.ll
+++ b/test/CodeGen/JS/getelementptr.ll
@@ -1,8 +1,9 @@
-; RUN: opt -S < %s -expand-getelementptr | llc -march=js | FileCheck %s
+; RUN: opt -S < %s -expand-getelementptr | llc | FileCheck %s
; Test simple getelementptr codegen.
target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
+target triple = "asmjs-unknown-emscripten"
; CHECK: function _getelementptr([[VAL_P:\$[a-z_]+]]) {
; CHECK: [[GEP:\$[a-z_]+]] = (([[GEPINT:\$[a-z_]+]]) + 588)|0;
diff --git a/test/CodeGen/JS/global-alias.ll b/test/CodeGen/JS/global-alias.ll
index b6efc0e7e7..9d39f7b29d 100644
--- a/test/CodeGen/JS/global-alias.ll
+++ b/test/CodeGen/JS/global-alias.ll
@@ -1,7 +1,10 @@
-; RUN: llc -march=js < %s | FileCheck %s
+; RUN: llc < %s | FileCheck %s
; Handle global aliases of various kinds.
+target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
+target triple = "asmjs-unknown-emscripten"
+
@pri = internal global [60 x i8] zeroinitializer
@pub = global [60 x i8] zeroinitializer
diff --git a/test/CodeGen/JS/globals.ll b/test/CodeGen/JS/globals.ll
index 4ae83eedb2..4ccf972e13 100644
--- a/test/CodeGen/JS/globals.ll
+++ b/test/CodeGen/JS/globals.ll
@@ -1,7 +1,10 @@
-; RUN: llc -march=js %s -o - | FileCheck %s
+; RUN: llc < %s | FileCheck %s
; Test simple global variable codegen.
+target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
+target triple = "asmjs-unknown-emscripten"
+
; CHECK: function _loads() {
; CHECK: [[VAR_t:\$[a-z]+]] = HEAP32[2]|0;
; CHECK: [[VAR_s:\$[a-z]+]] = +HEAPF64[2];
diff --git a/test/CodeGen/JS/invariant-intrinsics.ll b/test/CodeGen/JS/invariant-intrinsics.ll
index dc156a9ffb..b64355f83b 100644
--- a/test/CodeGen/JS/invariant-intrinsics.ll
+++ b/test/CodeGen/JS/invariant-intrinsics.ll
@@ -1,8 +1,11 @@
-; RUN: llc -march=js < %s | not grep invariant
+; RUN: llc < %s | not grep invariant
; llc currently emits no code or bookkeeping for invariant intrinsic calls
; or declarations.
+target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
+target triple = "asmjs-unknown-emscripten"
+
declare void @bar(i8*)
define void @foo() {
diff --git a/test/CodeGen/JS/lifetime-intrinsics.ll b/test/CodeGen/JS/lifetime-intrinsics.ll
index e3d8560e30..46f613bfa3 100644
--- a/test/CodeGen/JS/lifetime-intrinsics.ll
+++ b/test/CodeGen/JS/lifetime-intrinsics.ll
@@ -1,8 +1,11 @@
-; RUN: llc -march=js < %s | not grep lifetime
+; RUN: llc < %s | not grep lifetime
; llc currently emits no code or bookkeeping for lifetime intrinsic calls
; or declarations.
+target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
+target triple = "asmjs-unknown-emscripten"
+
declare void @bar(i8*)
define void @foo() {
diff --git a/test/CodeGen/JS/mem-intrinsics.ll b/test/CodeGen/JS/mem-intrinsics.ll
index 995d70d535..d59a6a6463 100644
--- a/test/CodeGen/JS/mem-intrinsics.ll
+++ b/test/CodeGen/JS/mem-intrinsics.ll
@@ -1,7 +1,10 @@
-; RUN: llc -march=js < %s | FileCheck %s
+; RUN: llc < %s | FileCheck %s
; llc should emit small aligned memcpy and memset inline.
+target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
+target triple = "asmjs-unknown-emscripten"
+
; CHECK: test_unrolled_memcpy
; CHECK: HEAP32[$d+0>>2]=HEAP32[$s+0>>2]|0;HEAP32[$d+4>>2]=HEAP32[$s+4>>2]|0;HEAP32[$d+8>>2]=HEAP32[$s+8>>2]|0;HEAP32[$d+12>>2]=HEAP32[$s+12>>2]|0;HEAP32[$d+16>>2]=HEAP32[$s+16>>2]|0;HEAP32[$d+20>>2]=HEAP32[$s+20>>2]|0;HEAP32[$d+24>>2]=HEAP32[$s+24>>2]|0;HEAP32[$d+28>>2]=HEAP32[$s+28>>2]|0;
define void @test_unrolled_memcpy(i8* %d, i8* %s) {
diff --git a/test/CodeGen/JS/phi.ll b/test/CodeGen/JS/phi.ll
index 517f73cba3..cef01ce2f4 100644
--- a/test/CodeGen/JS/phi.ll
+++ b/test/CodeGen/JS/phi.ll
@@ -1,8 +1,11 @@
-; RUN: llc -march=js < %s | FileCheck %s
+; RUN: llc < %s | FileCheck %s
; Phi lowering should check for dependency cycles, including looking through
; bitcasts, and emit extra copies as needed.
+target datalayout = "e-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-p:32:32:32-v128:32:128-n32-S128"
+target triple = "asmjs-unknown-emscripten"
+
; CHECK: while(1) {
; CHECK: $k$phi = $j;$j$phi = $k;$k = $k$phi;$j = $j$phi;
; CHECK: }