Files
pplus-library/mojo/probes/godbolt-target-cpu.mojo
alexm 568474d52f
Test (in pplus-core) / in-core (push) Failing after 28m44s
Initial commit
2026-11-12 22:23:48 -05:00

13 lines
609 B
Mojo

# probe: built with --target-cpu x86-64-v3, does the listing of String's ==, which the standard library compares with SIMD, use 256-bit AVX2 (ymm) and never AVX-512 (zmm), whichever of godbolt's machines answers? (without a target CPU, mojo build targets the machine it runs on, and on 2026-11-12 one of godbolt's answered library/mojo/local/demo.mojo with zmm)
# mode: both
# args: --target-cpu x86-64-v3
# stdin: GATTACA GATTACA\n
# expect-stdout: True
def same(a: String, b: String) -> Bool:
return a == b
def main() raises:
var w = input().split(" ")
print(same(String(w[0]), String(w[1])))