Hi Andrew. >> This assumes that int never has more bits then size_t. This is not >> guaranteed. The x32 ABI uses 32bit addresses and supports 64bit integers >> (https://lwn.net/Articles/456731/). It depends on the compiler if int >> has 32 or 64bit.
I think Heinrich is right to be worried about this. > This wouldn't resolve the issue, because the glpk code supports only > ILP32 and LP64 programming models, where int is assumed to be 32-bit; > this is checked in the routine glp_init_env (see glpk/src/env/env.c). However, it is easy to guard against this just in case. We can change the "if (sizeof(void *) != sizeof(size_t))" in minisat1.c to something like "if (sizeof(void *) != sizeof(size_t) || sizeof(int) > sizeof(size_t))" which should catch x32 variants with 64 bit ints. As I said back in March, there is a C interface available for the C++ MiniSat, so it may be possible to hook a more recent version to GLPK. I am planning to work on this at some point - if there is interest I can look into it earlier. Best Regards, Chris Matrakidis _______________________________________________ Help-glpk mailing list [email protected] https://lists.gnu.org/mailman/listinfo/help-glpk
