Skip to content

SOMns command-line interface without launcher script (som-native) #338

Description

@smarr

When not using the launcher script som, we seem to have a few issues.

  • ./som-native errors with a NPE
  • having som-native in another folder gives a cryptic error

@sophie-kaleba you have any other issues?

NPE

./som-native
VM arguments, need to come before any application arguments:

  --platform file-name   SOM Platform module to be loaded
                         file-name defaults to 'core-lib/Platform.ns'
  --kernel file-name     SOM Kernel module to be loaded
                         file-name defaults to 'core-lib/Kernel.ns'

  --debug                Run in Truffle Debugger/REPL
  --web-debug            Start web debugger

  --profile              Enable the TruffleProfiler
  --dynamic-metrics      Enable the DynamicMetrics tool
  --si-candidates        Enable the Super-instruction candidate tool
  --coveralls REPO_TOKEN Enable the Coverage tool and reporting to Coveralls.io
Exception in thread "main" org.graalvm.polyglot.PolyglotException: java.lang.NullPointerException
	at som.interpreter.SomLanguage$ShutdownContext.execute(SomLanguage.java:265)
	at <SOMns> null(Unknown)
	at org.graalvm.polyglot.Context.eval(Context.java:344)
	at som.Launcher.main(Launcher.java:46)
Original Internal Error:
java.lang.NullPointerException
	at som.interpreter.SomLanguage$ShutdownContext.execute(SomLanguage.java:265)
	at org.graalvm.compiler.truffle.runtime.OptimizedCallTarget.callProxy(OptimizedCallTarget.java:476)
	at org.graalvm.compiler.truffle.runtime.OptimizedCallTarget.callRoot(OptimizedCallTarget.java:451)
	at org.graalvm.compiler.truffle.runtime.OptimizedCallTarget.callBoundary(OptimizedCallTarget.java:421)
	at com.oracle.svm.truffle.api.SubstrateOptimizedCallTarget.doInvoke(SubstrateOptimizedCallTarget.java:135)
	at org.graalvm.compiler.truffle.runtime.OptimizedCallTarget.callIndirect(OptimizedCallTarget.java:339)
	at org.graalvm.compiler.truffle.runtime.OptimizedCallTarget.call(OptimizedCallTarget.java:329)
	at com.oracle.truffle.polyglot.PolyglotContextImpl.eval(PolyglotContextImpl.java:821)
	at org.graalvm.polyglot.Context.eval(Context.java:344)
	at som.Launcher.main(Launcher.java:46)
Caused by: Attached Guest Language Frames (1)

Cryptic Error

cp som-native core-lib
cd core-lib
./som-native TestSuite/TestRunner.ns
Exception in thread "main" org.graalvm.polyglot.PolyglotException: java.lang.RuntimeException: java.io.FileNotFoundException: core-lib/Platform.ns

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugFixes an issue, incorrect implementation

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions