NO

Recent Posts

Pages: 1 2 [3] 4 5 ... 10
21
Bug reports / Unexpected debugging behavior
« Last post by Werner on October 05, 2020, 01:09:26 pm »
Trying to debug with no breakpoint selected works as expected.

But calling the debugger with an active breakpoint (or with the option "Always break on entry-point" enabled) results in an assembly listing.

On the other hand, even with the option "Always break on entry-point" disabled the debugger breaks right there.

Am I missing any special setting?

(I didn't include a listing because I believe that this behavior is not code-related.)

Werner
22
Bug reports / Re: Speed Optimization: buggy or am I terribly missing something?
« Last post by Werner on October 05, 2020, 12:58:40 pm »
Thank you very much for your advice!
23
Bug reports / Re: Speed Optimization: buggy or am I terribly missing something?
« Last post by Pelle on October 04, 2020, 03:13:05 pm »
It's a bug (somewhere in the alias analyzer). It seems you can work around it, for now, by changing:
Code: [Select]
temp = a_arr[i];  // ... save element to sort, ...into:
Code: [Select]
volatile int temp = a_arr[i];  // ... save element to sort, ...
24
Beginner questions / Re: Open File Dialog Example
« Last post by iwrbc on October 02, 2020, 09:58:12 am »
Thank you both.
25
Bug reports / Re: Speed Optimization: buggy or am I terribly missing something?
« Last post by frankie on October 02, 2020, 09:34:27 am »
The code serves only to demonstarte an algorithm. So I could just turn off optimizing at all. I only thought, my observations might be useful.
Thanks Werner.
We need as many as possible samples for a better debugging.
Welcome on the forum!
26
Beginner questions / Re: Open File Dialog Example
« Last post by TimoVJL on October 02, 2020, 07:16:52 am »
A tool for searching GUIDs from libs
https://forum.pellesc.de/index.php?topic=7293.msg27680#msg27680

const GUID CLSID_FileOpenDialog = {0xDC1C5A9C,0xE88A,0x4DDE,0xA5,0xA1,0x60,0xF8,0x2A,0x20,0xAE,0xF7};
const GUID IID_IFileDialog = {0x42F85136,0xDB7E,0x439C,0x85,0xF1,0xE4,0x07,0x5D,0x13,0x5F,0xC8};

27
Beginner questions / Re: Open File Dialog Example
« Last post by algernon_77 on October 02, 2020, 02:35:13 am »
Hi there!

Just including the headers is not enough, the linker should know where to find CLSID_FileOpenDialog and IID_IFileDialog (they're not exported from the default libraries).
Try adding ole32.lib and uuid.lib to the linker library list (Project Options->Linker->Library and object files), that should do the trick.

Regards!
28
Bug reports / Re: Speed Optimization: buggy or am I terribly missing something?
« Last post by John Z on October 02, 2020, 12:19:55 am »
Hi Werner,

I could only suggest that because Pelle has identified some issues in the optimizer, based on other similar bug reports, and this has resolved (worked around) the problem for other users.   I believe Pelle is looking into the optimizer algorithms involved for possible improvements in future versions.

Welcome to the forum!

 Regards,
John Z
29
Beginner questions / Open File Dialog Example
« Last post by iwrbc on October 01, 2020, 09:33:51 pm »
Hi,
I am experiencing a problem when I use the file dialog from the website smorgasbordet. I do not understand it.
What I first did: I used the program 'as is' and it worked. Then I copied the code my own program, line by line, and got an error very soon.
The code is:
Code: [Select]
HRESULT Simple_FileOpenDialog(HWND hwndParent)
{
    IFileOpenDialog *pfod = NULL;  /* (IFileSaveDialog is similar) */

    // Create the File Open Dialog COM object.
    HRESULT hr = CoCreateInstance(&CLSID_FileOpenDialog, NULL, CLSCTX_INPROC_SERVER, &IID_IFileDialog, (void **)&pfod);
The last line here gives two linker errors:
Unresolved external symbol 'CLSID_FileOpenDialog'
Unresolved external symbol 'IID_IFileDialog'
These symbols are in the file shobjidl.h which I included.
In fact, I included all headers as in the sample:
Code: [Select]
#include <windows.h>
#define COBJMACROS
#include <shobjidl.h>       /* for IFileDialog, IFileOpenDialog, IFileSaveDialog */
#include <knownfolders.h>   /* for known folder APIs and definitions */
#include <wchar.h>

I have no idea what I am doing wrong. Any suggestions? Would be appreciated...
30
Bug reports / Re: Speed Optimization: buggy or am I terribly missing something?
« Last post by Werner on October 01, 2020, 05:18:15 pm »
Thanks a lot for your advice, John Z. I already tried this and it does work.

But to me, is seems to be a mere workaround. "volatile" is intended for different uses. I'd prefer a better working optimizer.

But then again, it doesn't count for much. The code serves only to demonstarte an algorithm. So I could just turn off optimizing at all. I only thought, my observations might be useful.
Pages: 1 2 [3] 4 5 ... 10