# Send assembler file to remote machine to run
scp Cprograms/start.S home:/home/akilan/cheri/output/sdk/bin/
scp Cprograms/main.c home:/home/akilan/cheri/output/sdk/bin/

# scp cheri.S home:/home/akilan/cheri/output/sdk/bin/

# Run compiled instruction remotely
# ssh home 'cd /home/akilan/cheri/output/sdk/bin/ && ./clang   --target=riscv64-unknown-elf   -march=rv64gcxcheri -mabi=l64pc128 -nostdlib -nostartfiles   -Wl,-Ttext=0x80000000 -o testC cheri.S'

ssh home 'cd /home/akilan/cheri/output/sdk/bin/ && ./clang   --target=riscv64-unknown-elf   -march=rv64gcxcheri -mabi=l64pc128 -nostdlib -nostartfiles   -Wl,-Ttext=0x80000000 -o testC start.S main.c'

# ssh home 'cd /home/akilan/cheri/output/sdk/bin/ && ./clang   --target=riscv64-unknown-elf   -march=rv64gcxcheri -mabi=lp64d -nostdlib -nostartfiles   -Wl,-Ttext=0x80000000 -o testC start.S main.c'

# Disassembly ouput
ssh home 'cd /home/akilan/cheri/output/sdk/bin/ && ./llvm-objdump -d testC'

# Copy file back for testing
scp home:/home/akilan/cheri/output/sdk/bin/testC .
