Russell Wallace wrote:
And running the resulting program, produces correct output, but on exit shows a heap corruption, with an error message in a pop-up window that unknowingly does not allow copy paste, but it's in
I've no problem with your program. Only issue I see with MSVC-2019 in debug-mode ('-MDd -RTC1 -RTCu' in CFLAGS and using mpir.dll), is in speed.exe. When running: speed -c -s 10(10)1000 mpn_preinv_divrem_1f.3333 gives this call-stack: speed!failwithmessage(void * retaddr = 0x0006e5c7, int crttype = 1, int errnum = 4, char * msg = 0x0053d5e8 "Stack area around _alloca memory reserved by this function is corrupted.Address: 0x0053D780.Size: 220.Allocation number within this function: 1.Data: <a???")+0x1ec speed!_RTC_AllocaFailure(void * retaddr = 0x0006e5c7, struct _RTC_ALLOCA_NODE * pn = 0x0053d760, int num = 1)+0xd2 speed!_RTC_CheckStackVars2(void * frame = 0x0053d8e4, struct _RTC_framedesc *, struct _RTC_ALLOCA_NODE * allocaList = 0x0053d760)+0xa6 speed!speed_mpn_preinv_divrem_1f(struct speed_params * s = 0x001206a0)+0x407 speed!speed_measure(<function> * fun = 0x0006e1c0, struct speed_params * s = 0x001206a0)+0xbf speed!run_one(struct _iobuf * fp = 0x61fd5a78, struct speed_params * s = 0x001206a0, long prev_size = 0x1e)+0x32c speed!run_all(struct _iobuf * fp = 0x61fd5a78)+0x188 speed!main(int argc = 5, char ** argv = 0x00747750)+0xa6a speed!invoke_main(void)+0x33 ... Increasing the stack with 'LDFLAGS += -stack:5000000' does not help. -- --gv -- You received this message because you are subscribed to the Google Groups "mpir-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to mpir-devel+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/mpir-devel/146f5e9f-0f8b-5126-04ad-22b555373f38%40gmail.com.