More support for finding original source code from transformed code

Open
#482 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
25/100
Issue type
Feature
Clarity
Needs clarification
Activity status
Stale
Tech stack
c, fortran, python
Domain
compilers, hpc

Research direction

No specific file, test, or entry point is identified. Start by tracing how transformed source is generated, then investigate how original Fortran line information could be retained through transformations toward SIR or CUDA and exposed for a C stack trace. Done would mean defining and implementing a reliable way to find the original source location from transformed-code line information.

Written by the indexing model from the issue text.

Description

enhancement question

During my presentation the issue was raised by a user that it might be difficult to understand a crash: it will provide a line number that is potentially completely useless in the original source code.

It could be useful if we could 'annotate' our transformed source code with the original line numbers. So if the binary crashes, we look at the line number in the transformed code, to easily find the original code.

This is probably not an issue for a CS debugging transforms or so, but could be useful for natural scientists to find science problems (NANs, unstable solutions or so)?

ATM most transforms leave the code similar enough to identify the original code. But if we think of going via SIR to cuda ... then having a potential way of finding from a C stack trace the original Fortran lines could be quite useful.

Dominant language
Python
Stars
137
Forks
36
Avg merge
6d 16h
Merged PRs (30d)
18

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from stfc/PSyclone

All issues in stfc/PSyclone

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.