Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kill_Procs test fails as killed process exits with error code #36

Open
Flamefire opened this issue May 28, 2018 · 2 comments
Open

Kill_Procs test fails as killed process exits with error code #36

Flamefire opened this issue May 28, 2018 · 2 comments

Comments

@Flamefire
Copy link

The GASPI command gaspi_proc_kill kills a remote process. However the return code of the killed process is unspecified. In GPI2 the remote process calls exit(-1) so an error code is set.

This results in a test failure when this error code is propagated.

Suggestion: As gaspi_proc_kill is a user request to terminate the process, it should not return an error code. So call exit(0) instead.

@mrahn
Copy link
Contributor

mrahn commented Jun 1, 2018

I am confused:

  • "kills a remote process" -> No, according to the spec: "sends an interrupt signal".
  • "In GPI2" -> Are you talking about the test suite? Can you elaborate please?

@Flamefire
Copy link
Author

The spec further says:

gaspi_proc_kill sends an interrupt signal to the Gaspi process incorporating the rank given by parameter rank . This can be used, for example, to realise(sic!) the registration of a user defined signal handler function which ensures the controlled shut down of an entire Gaspi application at the global level if the application receives an interrupt signal ( STRG + C ) in the interactive master process.
Every application should register such or a similar signal handler (c. f. listing 9).

In case of successful procedure completion, i. e. return value GASPI_SUCCESS , the remote
process has been terminated.

In this case I'm even escalating this as a bug in GPI2 that it does not adhere to the spec and simply calls exit(-1) instead of sending SIGINT:

_exit(-1);

  • "In GPI2": I mean
    _exit(-1);

    The testsuite tests this function:
    ASSERT(gaspi_proc_kill( i, GASPI_BLOCK));

    Hence there will be a process with non-zero exitcode spawned by the testsuite which may or may not make the test-fail depending on whether the error-code is propagated to the spawner/gaspi_run

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants