diff options
| author | John Criswell <criswell@uiuc.edu> | 2004-04-12 16:42:43 +0000 |
|---|---|---|
| committer | John Criswell <criswell@uiuc.edu> | 2004-04-12 16:42:43 +0000 |
| commit | b7147b33a032510c59940c78841ea6ec2dc88948 (patch) | |
| tree | 69b2188342efa62e69d6646d08233d5ee2404648 /llvm | |
| parent | 7a57647f974128d17a188e8bde4a0c5940048344 (diff) | |
| download | bcm5719-llvm-b7147b33a032510c59940c78841ea6ec2dc88948.tar.gz bcm5719-llvm-b7147b33a032510c59940c78841ea6ec2dc88948.zip | |
Added testcase for the llvm.readport and llvm.writeport intrinsics.
llvm-svn: 12868
Diffstat (limited to 'llvm')
| -rw-r--r-- | llvm/test/Regression/CodeGen/X86/ioport.llx | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/llvm/test/Regression/CodeGen/X86/ioport.llx b/llvm/test/Regression/CodeGen/X86/ioport.llx new file mode 100644 index 00000000000..37f80d2fb85 --- /dev/null +++ b/llvm/test/Regression/CodeGen/X86/ioport.llx @@ -0,0 +1,18 @@ +; RUN: llvm-as < %s | llc -march=x86 + +implementation + +declare int %llvm.readport (ushort) +declare void %llvm.writeport (int, ushort) + +uint %in (uint %p) { + %i1 = call int(ushort)* %llvm.readport (ushort 255) + ret uint 5 +} + + +uint %out (uint %p) { + call void(int, ushort)* %llvm.writeport (int 1, ushort 255) + ret uint 5 +} + |

