Example #1
0
#!/usr/bin/env python3
from mupq import mupq
from interface import *

import sys

if __name__ == "__main__":
    args, rest = parse_arguments()
    riscv, settings = get_platform(args)
    with riscv:
        if "--nostack" not in sys.argv:
            test = mupq.StackBenchmark(settings, riscv)
            test.test_all(rest)

        if "--nospeed" not in sys.argv:
            test = mupq.SpeedBenchmark(settings, riscv)
            test.test_all(rest)

        if "--nohashing" not in sys.argv:
            test = mupq.HashingBenchmark(settings, riscv)
            test.test_all(rest)

        # if "--nosize" not in sys.argv:
        #     test = mupq.SizeBenchmark(settings, riscv)
        #     test.test_all(rest)
Example #2
0
#!/usr/bin/env python3
from mupq import mupq
from interface import parse_arguments, get_platform

if __name__ == "__main__":
    args, rest = parse_arguments()
    platform, settings = get_platform(args)
    with platform:
        schemes = [
            s for s in rest
            if s not in ['--nostack', '--nospeed', '--nohashing', '--nosize']
        ]
        if "--nostack" not in rest:
            test = mupq.StackBenchmark(settings, platform)
            test.test_all(schemes)

        if "--nospeed" not in rest:
            test = mupq.SpeedBenchmark(settings, platform)
            test.test_all(schemes)

        if "--nohashing" not in rest:
            test = mupq.HashingBenchmark(settings, platform)
            test.test_all(schemes)

        if "--nosize" not in rest:
            test = mupq.SizeBenchmark(settings, platform)
            test.test_all(schemes)
Example #3
0
#!/usr/bin/env python3
from mupq import mupq
from interface import M4Settings, M4

import sys

if __name__ == "__main__":
    with M4() as m4:
        if "--nostack" not in sys.argv:
            test = mupq.StackBenchmark(M4Settings(), m4)
            test.test_all(sys.argv[1:])

        if "--nospeed" not in sys.argv:
            test = mupq.SpeedBenchmark(M4Settings(), m4)
            test.test_all(sys.argv[1:])

        if "--nohashing" not in sys.argv:
            test = mupq.HashingBenchmark(M4Settings(), m4)
            test.test_all(sys.argv[1:])

        if "--nosize" not in sys.argv:
            test = mupq.SizeBenchmark(M4Settings(), m4)
            test.test_all(sys.argv[1:])