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

[SPEC2006] Assertion failure ../../../../osprey/ir_tools/whirl2llvm.cxx:5815: ### WHIRL2llvm::STMT2llvm, intrinsic(521) not handled #33

Open
zqb-all opened this issue Oct 28, 2023 · 0 comments

Comments

@zqb-all
Copy link

zqb-all commented Oct 28, 2023

spec2k6 456.hmmer build fail.
one of the errors can be reproduce by the following code:

char buf[100];
void foo()
{
  strncpy(buf, buf+10, 10);
}

cmd

xcalcc -c a.c

error:

2023-10-28 10:40:55,053 - xcalcc - ERROR - !!! Log: (null) :Translating foo(0)

!!! DevWarn: foo :Stmt2llvm: ingore PRAGMA stmt now

### Assertion failure ../../../../osprey/ir_tools/whirl2llvm.cxx:5815:
### WHIRL2llvm::STMT2llvm, intrinsic(521) not handled
### For a.O in foo (xcalcc:583)
zengdage added a commit to zengdage/open64 that referenced this issue Jan 4, 2024
1. The w2ll will crash if compile the code like that:
```
typedef struct msa_struct {
  char **aseq;
  int    alen;
  int    nseq;
} MSA;

void WriteA2M1(MSA *msa)
{
  int  pos;
  char buf[64];
  int  cpl = 60;

  buf[cpl] = '\0';
  for (pos = 0; pos < msa->alen; pos+=cpl)
  {
    strncpy(buf, &(msa->aseq[0][pos]), cpl);
  }
}

```

2. Error Log:
```
Assertion failure ../../../../osprey/ir_tools/whirl2llvm.cxx:5815:
WHIRL2llvm::STMT2llvm, intrinsic(521) not handled
```

Signed-off-by: Zhijin Zeng <[email protected]>
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

1 participant