Skip to content

Commit

Permalink
PorcE: Add TODOs for issue #216.
Browse files Browse the repository at this point in the history
  • Loading branch information
arthurp committed Oct 10, 2017
1 parent 5476426 commit 66d9130
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions PorcE/src/orc/run/porce/GetField.java
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ public Object slowPath(final Object obj) {
return accessWithBoundary(accessor, obj);
} catch (final Exception e) {
CompilerDirectives.transferToInterpreter();
// TODO: Wrap exception to include Orc stack information. This will mean wrapping this in JavaException if needed and calling setBacktrace
execution.get().notifyOrcWithBoundary(new CaughtEvent(e));
throw HaltException.SINGLETON();
}
Expand Down
4 changes: 4 additions & 0 deletions PorcE/src/orc/run/porce/call/ExternalCPSDispatch.java
Original file line number Diff line number Diff line change
Expand Up @@ -82,13 +82,15 @@ public void specificDirect(final VirtualFrame frame, final Object target, final
throw e;
} catch (final ExceptionHaltException e) {
exceptionProfiles[0].enter();
// TODO: Wrap exception to include Orc stack information. This will mean wrapping this in JavaException if needed and calling setBacktrace
execution.get().notifyOrcWithBoundary(new CaughtEvent(e.getCause()));
counter.haltToken();
} catch (final HaltException e) {
exceptionProfiles[1].enter();
counter.haltToken();
} catch (final Exception e) {
exceptionProfiles[2].enter();
// TODO: Wrap exception to include Orc stack information. This will mean wrapping this in JavaException if needed and calling setBacktrace
execution.get().notifyOrcWithBoundary(new CaughtEvent(e));
counter.haltToken();
}
Expand Down Expand Up @@ -116,13 +118,15 @@ public void specific(final VirtualFrame frame, final Object target, final Object
throw e;
} catch (final ExceptionHaltException e) {
exceptionProfiles[0].enter();
// TODO: Wrap exception to include Orc stack information. This will mean wrapping this in JavaException if needed and calling setBacktrace
execution.get().notifyOrcWithBoundary(new CaughtEvent(e.getCause()));
counter.haltToken();
} catch (final HaltException e) {
exceptionProfiles[1].enter();
counter.haltToken();
} catch (final Exception e) {
exceptionProfiles[2].enter();
// TODO: Wrap exception to include Orc stack information. This will mean wrapping this in JavaException if needed and calling setBacktrace
execution.get().notifyOrcWithBoundary(new CaughtEvent(e));
counter.haltToken();
}
Expand Down
4 changes: 4 additions & 0 deletions PorcE/src/orc/run/porce/call/ExternalDirectDispatch.java
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,15 @@ public Object specific(final VirtualFrame frame, final Object target, final Obje
return invokeDirectWithBoundary(invoker, target, arguments);
} catch (final ExceptionHaltException e) {
exceptionProfiles[0].enter();
// TODO: Wrap exception to include Orc stack information. This will mean wrapping this in JavaException if needed and calling setBacktrace
execution.get().notifyOrcWithBoundary(new CaughtEvent(e.getCause()));
throw HaltException.SINGLETON();
} catch (final HaltException e) {
exceptionProfiles[1].enter();
throw e;
} catch (final Exception e) {
exceptionProfiles[2].enter();
// TODO: Wrap exception to include Orc stack information. This will mean wrapping this in JavaException if needed and calling setBacktrace
execution.get().notifyOrcWithBoundary(new CaughtEvent(e));
throw HaltException.SINGLETON();
}
Expand All @@ -58,13 +60,15 @@ public Object universal(final VirtualFrame frame, final Object target, final Obj
return invokeDirectWithBoundary(invoker, target, arguments);
} catch (final ExceptionHaltException e) {
exceptionProfiles[0].enter();
// TODO: Wrap exception to include Orc stack information. This will mean wrapping this in JavaException if needed and calling setBacktrace
execution.get().notifyOrcWithBoundary(new CaughtEvent(e.getCause()));
throw HaltException.SINGLETON();
} catch (final HaltException e) {
exceptionProfiles[1].enter();
throw e;
} catch (final Exception e) {
exceptionProfiles[2].enter();
// TODO: Wrap exception to include Orc stack information. This will mean wrapping this in JavaException if needed and calling setBacktrace
execution.get().notifyOrcWithBoundary(new CaughtEvent(e));
throw HaltException.SINGLETON();
}
Expand Down

0 comments on commit 66d9130

Please sign in to comment.