- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
I have tried to change my code to use all 64 bit integers and reals by using /integer_size:64 and /real_size:64 in my mixed-language program. It all seems to work fine and IVF seems to treat the string lengths passed via subroutines as 64 bit integers as well. But in my CVF version, I have trouble getting it to run correctly. It almost looks like it treats the lengths still as 32 bit variables. Can you tell me what size does each compiler use to pass the string lengths when the integer size is 64 bits?
Thanks,
Dave
Link kopiert
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
Why do you want to use 64-bit integers and reals by default?
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
Mostly ease of conversion. There are lots and lots of places where we have equivalenced variables, keeping them the same size eliminates a lot of issues with equivalencing. It also allows us to go ahead and use larger integers for numbering, which is convient in our models.
Where I have some C routines calling Fortran, the CVF compiler is getting an undefined pointer for the second argument of a Fortran function. The first is a character string and the second is an integer.The code works fine on the 64 bit IVF version, but doesn't on the 32 bit CVF version. Passing a 32 bit string size after the string or a 64 bit size seems to do the same thing, the FORTRAN isn't getting the second argument which is a 64 bit integer in both the C and Fortran (based on the /integer_size:64 compiler argument for the FORTRAN).
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
What exactly doesn't work? Have you made sure to use ATTRIBUTES C in CVF to get the C calling convention? You might be mixing C and STDCALL conventions.
- Als neu kennzeichnen
- Lesezeichen
- Abonnieren
- Stummschalten
- RSS-Feed abonnieren
- Kennzeichnen
- Anstößigen Inhalt melden
Okay, when I went back and changed the C code to pass a 32 bit int, I didn't change the function prototype. Changed that too and now it runs. I'm not much of a C programmer. Thanks for your help.

- RSS-Feed abonnieren
- Thema als neu kennzeichnen
- Thema als gelesen kennzeichnen
- Diesen Thema für aktuellen Benutzer floaten
- Lesezeichen
- Abonnieren
- Drucker-Anzeigeseite