i have a problem while using the stxxl library.
i use the vector and then sort it as the example program did, but when i run my program it throws a error :
[STXXL-ERRMSG] Buffer is not aligned: modulo 4096 = 4 (0xb37cb004)
Error in function virtual void stxxl::syscall_request::serve() Info: this=135398792 File descriptor=5 offset=0 buffer=0xb37cb004 bytes=2097152 type=WRITE nref= 2 ::write (static_cast<syscall_file*>(file_)->get_file_des (), buffer, bytes): Invalid argument
when i use the element of the vector, or i sort the vector, the error above was thrown;
how to sovle the problem, thank you very much, i have debuged it for a long time.
what is your operating system and compiler (including the version)?
also compile your program with -DSTXXL_VERBOSE_LEVEL=1 switch, run it and post here the output.
Are you using Linux? If yes: use multiples of 4K as block-sizes. This should solve your issue
Log in to post a comment.