Visual C++ configurations

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Visual C++ configurations

Luigi Ballabio

Hi all,
        I've just answered a poor soul on quantlib-users that asked about the  
difference between the various VC++ configurations we've defined. A  
few thoughts:

First: the nomenclature is cryptic. It's not obvious that CRTDLL  
stands for "common runtime dll." We should clarify the names.

Second, and perhaps most important: there's a mismatch between what we  
call release and what the default is for VC++ projects. If one asks  
for a new project, VC++ creates one with a Debug and a Release  
configuration. Unfortunately, they don't correspond to what we call  
release. If a user has compiled QuantLib in Release mode and tries to  
link it to its new application, he'll have an unexpected linking  
error.  What VC++ 7 calls "Release" is what we call "Release  
SingleThread"; what VC++ 8 and 9 calls "Release" is what we call  
"Release CRTDLL".

Needless to say, I'd like to fix this in future releases. For VC++ 8  
and 9, I'd call "Release" the default configuration (crtdll) and  
something like "Release (static runtime)" the current Release. Well,  
actually, I'm not even sure that I'd leave multiple configurations  
instead of just Debug/Release; on the one hand, they're confusing for  
most users, and on the other hand, a user that needs a particular  
runtime is likely to know what settings to change to obtain it. We can  
talk about this; at the very least, I'd switch the names.

For VC++ 7, I'm not so sure. For uniformity, I'd call Release what VC+
+ calls Release, i.e., the single-thread configuration. But doing so,  
we'd lose uniformity between VC++ versions; and I'm also concerned  
about QuantLibXL---Eric, does it support single-thread mode, or does  
it require the multi-threaded runtime? If the latter, we might want to  
use the crtdll configuration as default.

Thought anyone?

Later,
        Luigi



-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev
Reply | Threaded
Open this post in threaded view
|

Re: Visual C++ configurations

Simon Ibbotson
Just a quick thought from my own experience on multiple platforms... Release (static runtime) is more stable than Release (crtdll) for many purposes. Specifically, there are major problems with crtdll (both debug and release) when using from a Java environment. Even more complicatedly, many of these only occur with Microsoft IE7 and XP (other problems on Vista).
Usually, static runtime is much easier for distribution.

Simon


On Wed, Sep 3, 2008 at 10:28 PM, Luigi Ballabio <[hidden email]> wrote:

Hi all,
       I've just answered a poor soul on quantlib-users that asked about the
difference between the various VC++ configurations we've defined. A
few thoughts:

First: the nomenclature is cryptic. It's not obvious that CRTDLL
stands for "common runtime dll." We should clarify the names.

Second, and perhaps most important: there's a mismatch between what we
call release and what the default is for VC++ projects. If one asks
for a new project, VC++ creates one with a Debug and a Release
configuration. Unfortunately, they don't correspond to what we call
release. If a user has compiled QuantLib in Release mode and tries to
link it to its new application, he'll have an unexpected linking
error.  What VC++ 7 calls "Release" is what we call "Release
SingleThread"; what VC++ 8 and 9 calls "Release" is what we call
"Release CRTDLL".

Needless to say, I'd like to fix this in future releases. For VC++ 8
and 9, I'd call "Release" the default configuration (crtdll) and
something like "Release (static runtime)" the current Release. Well,
actually, I'm not even sure that I'd leave multiple configurations
instead of just Debug/Release; on the one hand, they're confusing for
most users, and on the other hand, a user that needs a particular
runtime is likely to know what settings to change to obtain it. We can
talk about this; at the very least, I'd switch the names.

For VC++ 7, I'm not so sure. For uniformity, I'd call Release what VC+
+ calls Release, i.e., the single-thread configuration. But doing so,
we'd lose uniformity between VC++ versions; and I'm also concerned
about QuantLibXL---Eric, does it support single-thread mode, or does
it require the multi-threaded runtime? If the latter, we might want to
use the crtdll configuration as default.

Thought anyone?

Later,
       Luigi



-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev
Reply | Threaded
Open this post in threaded view
|

Re: Visual C++ configurations

Ferdinando M. Ametrano-3
In reply to this post by Luigi Ballabio
Hi all

my 0.02€

> First: the nomenclature is cryptic. It's not obvious that CRTDLL
> stands for "common runtime dll." We should clarify the names.
it should actually stand for "C runtime dll"

> For VC++ 7, I'm not so sure.
I would leave it behind, in some fashion.
I mean: VC8 is 3 years old, and VC9 is a the first MS free compiler. I
wouldn't be that much concerned about the VC7 choice, as long as it's
documented. As far as my time and resources are concerned I probably
won't maintain it anymore.

> what VC++ 8 and 9 calls "Release" is what we call
> "Release CRTDLL".
> [...]
> Needless to say, I'd like to fix this in future releases. For VC++ 8
> and 9, I'd call "Release" the default configuration (crtdll) and
> something like "Release (static runtime)" the current Release.
fine with me

ciao -- Nando

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev
Reply | Threaded
Open this post in threaded view
|

Re: Visual C++ configurations

Eric Ehlers-2
In reply to this post by Luigi Ballabio
Hi Luigi,

On Wed, September 3, 2008 22:28, Luigi Ballabio wrote:
> I'm also concerned
> about QuantLibXL---Eric, does it support single-thread mode, or does
> it require the multi-threaded runtime? If the latter, we might want to
> use the crtdll configuration as default.

The latest release of log4cxx requires multithread (whether static or dynamic) and so in 0.9.6 the
SingleThread configurations have been dropped from the VC7 files for ObjectHandler, QuantLibAddin,
and QuantLibXL.

QuantLibXL supports 2 builds:
1) ObjectHandler and QuantLibXL in single XLL - may be built with any configuration
2) ObjectHandler and QuantLibXL in two separate XLLs - requires the CRTDLL configuration

Regards,
Eric

-------------------------
Eric Ehlers
nazcatech sprl | Brussels | http://www.nazcatech.be
Distributed computing for pricing analytics - Use Microsoft Excel as a client to the Grid


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev
Reply | Threaded
Open this post in threaded view
|

Re: Visual C++ configurations

Fabrice_CBA
In reply to this post by Luigi Ballabio
Hi all,

If I can give a humble newbie opinion:

Static runtime configuration is more natural and easier to understand
for a beginner in that kind of projects. Since it's self-contained and
easier to deploy, it makes it easier to use in the end. It might be more
difficult for a new audience to understand how to use quantlib if you
decide to make that configuration non-default, not to mention getting
rid of it all together.

>a user that needs a particular runtime is likely to know what settings
to change to obtain it.
True, however people that don't would primarily expect to be using
static runtime, no?. I know I was.

That beeing said, correcting the inconsistency with VC8&9 seems more
important. After all, Microsoft decided CRTDLL was the new default
configuration, so be it. I would vote for clearer names though. About
VC7, I agree with Fernando.

A plus,
Fabrice

-----Original Message-----
From: [hidden email]
[mailto:[hidden email]] On Behalf Of Luigi
Ballabio
Sent: Thursday, 4 September 2008 7:29 AM
To: QuantLib developers
Subject: [Quantlib-dev] Visual C++ configurations


Hi all,
        I've just answered a poor soul on quantlib-users that asked
about the difference between the various VC++ configurations we've
defined. A few thoughts:

First: the nomenclature is cryptic. It's not obvious that CRTDLL stands
for "common runtime dll." We should clarify the names.

Second, and perhaps most important: there's a mismatch between what we
call release and what the default is for VC++ projects. If one asks for
a new project, VC++ creates one with a Debug and a Release
configuration. Unfortunately, they don't correspond to what we call
release. If a user has compiled QuantLib in Release mode and tries to
link it to its new application, he'll have an unexpected linking error.
What VC++ 7 calls "Release" is what we call "Release SingleThread"; what
VC++ 8 and 9 calls "Release" is what we call "Release CRTDLL".

Needless to say, I'd like to fix this in future releases. For VC++ 8 and
9, I'd call "Release" the default configuration (crtdll) and something
like "Release (static runtime)" the current Release. Well, actually, I'm
not even sure that I'd leave multiple configurations instead of just
Debug/Release; on the one hand, they're confusing for most users, and on
the other hand, a user that needs a particular runtime is likely to know
what settings to change to obtain it. We can talk about this; at the
very least, I'd switch the names.

For VC++ 7, I'm not so sure. For uniformity, I'd call Release what VC+
+ calls Release, i.e., the single-thread configuration. But doing so,
we'd lose uniformity between VC++ versions; and I'm also concerned about
QuantLibXL---Eric, does it support single-thread mode, or does it
require the multi-threaded runtime? If the latter, we might want to use
the crtdll configuration as default.

Thought anyone?

Later,
        Luigi



------------------------------------------------------------------------
-
This SF.Net email is sponsored by the Moblin Your Move Developer's
challenge Build the coolest Linux based applications with Moblin SDK &
win great prizes Grand prize is a trip for two to an Open Source event
anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev

************** IMPORTANT MESSAGE *****************************      
This e-mail message is intended only for the addressee(s) and contains information which may be
confidential.
If you are not the intended recipient please advise the sender by return email, do not use or
disclose the contents, and delete the message and any attachments from your system. Unless
specifically indicated, this email does not constitute formal advice or commitment by the sender
or the Commonwealth Bank of Australia (ABN 48 123 123 124) or its subsidiaries.
We can be contacted through our web site: commbank.com.au.
If you no longer wish to receive commercial electronic messages from us, please reply to this
e-mail by typing Unsubscribe in the subject line.
**************************************************************




-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev
Reply | Threaded
Open this post in threaded view
|

Re: Visual C++ configurations

Ferdinando M. Ametrano-3
Hi Fabrice

> > a user that needs a particular runtime is likely to know what settings
> > to change to obtain it.
> True, however people that don't would primarily expect to be using
> static runtime, no?. I know I was.

I was too.

Anyway as Luigi pointed out if one asks for a new project, VC++ 8 and
9 create one with Debug and Release configurations: they will link
dynamically to the C runtime library. So if you look forward it makes
more sense to conform to this behavior.

ciao -- Nando

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev