summaryrefslogtreecommitdiff
path: root/mbld
diff options
context:
space:
mode:
authorOri Bernstein <ori@eigenstate.org>2018-03-23 00:24:17 -0700
committerOri Bernstein <ori@eigenstate.org>2018-03-23 10:37:04 -0700
commita94f75ac8f6a6365182191a55fad1e5723411457 (patch)
tree89abac491adf7bb2045a52530f609e8a07516fdc /mbld
parent65c3b339b547b49d1c1d11c56d86ca81f756e9be (diff)
downloadmc-a94f75ac8f6a6365182191a55fad1e5723411457.tar.gz
Fix the cpufeatures... er... features on plan 9.
Diffstat (limited to 'mbld')
-rw-r--r--mbld/bld.sub2
-rw-r--r--mbld/cpufeatures+plan9-x64.s9
-rw-r--r--mbld/cpufeatures+posixy-x64.s (renamed from mbld/cpufeatures+x64.s)0
3 files changed, 10 insertions, 1 deletions
diff --git a/mbld/bld.sub b/mbld/bld.sub
index 7374bb3..5f6b129 100644
--- a/mbld/bld.sub
+++ b/mbld/bld.sub
@@ -1,6 +1,6 @@
bin mbld =
build.myr
- cpufeatures+x64.s
+ cpufeatures+posixy-x64.s
deps.myr
libs.myr
install.myr
diff --git a/mbld/cpufeatures+plan9-x64.s b/mbld/cpufeatures+plan9-x64.s
new file mode 100644
index 0000000..a67e0c9
--- /dev/null
+++ b/mbld/cpufeatures+plan9-x64.s
@@ -0,0 +1,9 @@
+TEXT bld$cpufeatures+0(SB),$0
+ MOVL $0x1,AX
+ CPUID
+ MOVL CX,AX
+ ROLQ $32, AX
+ SHRQ $32, DX
+ ORQ DX, AX
+ RET
+
diff --git a/mbld/cpufeatures+x64.s b/mbld/cpufeatures+posixy-x64.s
index 8202ca1..8202ca1 100644
--- a/mbld/cpufeatures+x64.s
+++ b/mbld/cpufeatures+posixy-x64.s