cpc icon indicating copy to clipboard operation
cpc copied to clipboard

CPC compilation does not finish

Open vbmithr opened this issue 11 years ago • 4 comments

It stops at

/tmp/cpc-0.9.1/bin/cpc.native --out /tmp/cil-VkoZo7Zq.cil.c --warnall /tmp/cil-1o8J_C5l.i

where the program never finishes (and use 100% CPU).

This happens both on the git and the released version.

vbmithr avatar Feb 10 '15 11:02 vbmithr

With OCaml 4.01.0, I get tons of warnings from GCC but compilation does finish successfully. Did you try compiling the latest git snapshot from develop branch? Your /tmp/cpc-0.9.1 seems to indicate otherwise, and I honnestly can't remember if this a bug I have fixed in the past already or not.

Also, I need to update CPC to the latest CIL version. If you use OCaml 4.02, this could be the bug fixed by this patch in CIL (but not imported into CPC yet): https://github.com/cil-project/cil/commit/681f17e618282436b8168278af4464036623aaf1#diff-3f5b51e1b5debd0c7012f96377e592c6R643

kerneis avatar Feb 10 '15 12:02 kerneis

On 10/02/2015 13:23, Gabriel Kerneis wrote:

With OCaml 4.01.0, I get tons of warnings from GCC but compilation does finish successfully. Did you try compiling the latest git snapshot from develop branch? Your /tmp/cpc-0.9.1 seems to indicate otherwise, and I honnestly can't remember if this a bug I have fixed in the past already or not.

I tried both, same result.

Also, I need to update CPC to the latest CIL version. If you use OCaml 4.02, this could be the bug fixed by this patch in CIL (but not imported into CPC yet): cil-project/cil@681f17e#diff-3f5b51e1b5debd0c7012f96377e592c6R643 https://github.com/cil-project/cil/commit/681f17e618282436b8168278af4464036623aaf1#diff-3f5b51e1b5debd0c7012f96377e592c6R643

Interesting. Yeah, it would be nice if you could do that. I'll have a look on how I can do this myself too.

Vincent

vbmithr avatar Feb 10 '15 12:02 vbmithr

Interesting. Yeah, it would be nice if you could do that. Ill have a look on how I can do this myself too.

Unfortunately, it's going to be hard to do because CIL's infrastructure has changed quite a bit (which is why I postponed the release many times, etc.). And time is too scarce too. But please, go ahead and give it a go. Feel free to ask me any question, I'd be glad to merge a patch. (Mostly, you need to fetch CIL's develop branch, git merge, and resolve the gazillion conflicts.)

kerneis avatar Feb 10 '15 13:02 kerneis

On 10/02/2015 14:01, Gabriel Kerneis wrote:

Unfortunately, it's going to be hard to do because CIL's infrastructure has changed quite a bit (which is why I postponed the release many times, etc.). And time is too scarce too. But please, go ahead and give it a go. Feel free to ask me any question, I'd be glad to merge a patch. (Mostly, you need to fetch CIL's develop branch, git merge, and resolve the gazillion conflicts.)

I managed to get it compile by using the patch you mentionned. I will submit a PR.

Vincent

vbmithr avatar Feb 10 '15 13:02 vbmithr