Silverfrost Forums

Welcome to our forums

_SetMaximumIOBufferSize error

16 Aug 2017 11:09 #20019

I am currently getting the following error:

Within file CLEARWIN64.DLL In _SetMaximumIOBufferSize

I haven't tested this exact version in 32bit (as quite a few changes to be done).

Is this error too generic, or is there something I can start looking for?

16 Aug 2017 2:38 #20022

If I run a pure Fortran application, this doesn't happen - but if I start a C++ Qt executable which calls this Fortran application as a DLL, then it happens.

Perhaps a case of increasing a buffer size somewhere?

16 Aug 2017 3:12 #20023

Can you provide sample code that demonstrates this failure?

16 Aug 2017 3:48 #20024

I would have to share the whole code - perhaps Robert could send me a test version of CLEARWIN64.dll with a very large buffer size (related to SetMaximumIOBufferSize) just to see if the problem goes away?

Thanks

16 Aug 2017 4:11 #20025

The default buffer size is 32767 and this can be increased by a call to SET_MAXIMUM_IO_BUFFER_SIZE@ at the start of the program.

C_EXTERNAL SET_MAXIMUM_IO_BUFFER_SIZE@ '__SetMaximumIOBufferSize' (VAL)



extern void SetMaximumIOBufferSize(int) '__SetMaximumIOBufferSize';
29 Nov 2017 3:26 #20891

Thanks for this. I tried increasing it to a very large size but I am still getting the same error.

It appears consistently (i.e. I can reproduce it in specific instances), but it happens on various, unrelated parts of the code. I need to upload a rather large part of code and I will contact Robert (as C++ clearwin64 and c++ related) about this.

Thanks

29 Nov 2017 4:27 #20892

Wanted to add that I also used GlobalMemoryStatus@ to check max memory that the process can commit. I compared what happens when it is Qt->Qt dll->fortran dll, and Fortran->Qt dll->Fortran dll, but there was no significant difference, so the bug is more subtle than Qt taking up more memory than Fortran.

30 Nov 2017 9:37 #20907

The documentation is not strictly accurate.

The subroutine already existed in salflibc.dll and clearwin64.dll. It was already exported by salflibc.dll but was not exported by clearwin64.dll.

With 8.20 this subroutine is now also exported by clearwin64.dll.

This omission became apparent as a result of the above discussion.

As far as I know the subroutine was previously undocumented and possibly never used nor needed.

Please login to reply.