Skip to content

Illegal lvalue with PGI compiler 19.9 #2976

Closed

Description

@sheltongeosx

Hi Dear Developers:

I am using PGI compiler 19.9 to built OpenBLAS on IBM Power8(commit 60ab9c7, 2020-11-04) and it failed with the error mesages:

... ...
PGC-S-0058-Illegal lvalue (../kernel/power/../arm/zdot.c: 77)
PGC-S-0058-Illegal lvalue (../kernel/power/../arm/zdot.c: 78)
PGC/power Linux 19.9-0: compilation completed with severe errors

Any idea to fix it?

Best,
Shelton

Activity

  1. brada4 commented on Nov 6, 2020

    @brada4
    Contributor

    You need to produce output from preprocessed file, CREAL is either C creal or by mistake struct() based emulation of it, somewhere in includes - hard to guess.
    With gcc that would be running cpp sitting next to gcc with same params and picking the output, then compiling that output with gcc and same params, probably PGI has guide somewhere how to "output preprocessed C ffile"

    76: #if !defined(__POWER__) 
    77:        CREAL(result) = dot[0];
    78:        CIMAG(result) = dot[1];
    79: #else
    
  2. martin-frbg commented on Nov 6, 2020

    @martin-frbg
    Collaborator

    These two lines are not supposed to be used on ppc, perhaps PGI does not define __POWER__?
    Try changing the ifdef to __PPC__ (like it is a few lines above - both instances were from same commit #2731, probably got distracted in between and it did not matter with the compiler I had used at the time)

  3. sheltongeosx commented on Nov 6, 2020

    @sheltongeosx
    Author

    @brada4 @martin-frbg
    Andrew, Martin,
    Thank you very much for pointing me to the right point. By adding "#define __POWER__1" to common.h it is successfully built now!

    Thanks,
    Shelton

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions