|
may i please inquire typical build durations for C++ projects
as for myself 36s for a project w/ 21 source files w/ a few hundred LOC in each
i have reason for asking i.e. to wit am putting finishing touches on an "include-only-what-is-utilized" program however the program may be of little use as process durations are lengthy as iowiu compiles each source in a provided list to determine if each include in each source is required relying on compile error report to determine same . iowiu run-time duration for entire list therefor goes as SUM (over source files) source compile duration * number of includes in source . i expect to use it for myself on occasion . but wish to learn if it would be useful to others . current version eliminated many unneeded includes . project build time went down from a leisurely 35s to blazing 32s . iowiu processing duration was approximately 100m . further if any interest is shown in such a program can provide same via Tech Tip .
[EDIT] forgot to mention attempted include-what-you-use but found it unworkable for my project as it failed to build w/o compile error upon applying its recommendations . it is more advanced of course but it seems a work in progress .
modified 13-Apr-23 13:17pm.
|
|
|
|
|
BernardIE5317 wrote: "include-only-what-is-utilized"
Static analysis cannot determine that for modern applications.
That is because they can and often do load code dynamically.
Although it might be useful for small tools.
Did you google for existing solutions to the same problem before creating your own tool?
|
|
|
|
|
thank you for your kindly provided information . may i please inquire as it seems to me any code which is loaded whether static dynamic linking or dynamic loading must i presume 1st be built by its author . iowiu is intended as a build time tool . as for your inquiry yes i investigated include-what-you-use but found it unworkable for my project as per added [EDIT] .
|
|
|
|
|
With dynamic loading it is not loaded at all until specific code runs (not compiles) so static analysis cannot find it because there is no linkage to find.
|
|
|
|
|
thank you for your helpful information . may i please inquire are these dynamically loaded code associated w/ an #include declaration in the calling/loading code file ?
|
|
|
|
|
|
i am familiar w/ loading of DLLs . as they are not associated w/ any #include directive i still do not understand your original post re/ un-usefulness of iowiu re/ same . i wish to stress iowiu is strictly for the processing of #include directives .
|
|
|
|
|
Because
1. You cannot detect that the dll was loaded unless the application is running. Not to mention that all code paths would need to be exercised.
2. To load the dll it must be packaged with the product (for most cases.)
|
|
|
|
|
it appears i did not describe iowiu properly . my meaning of "include only what is utilized" refers only to C++ #include declaration . it has nothing to do re/ DLLs which may be utilized .
|
|
|
|
|
BernardIE5317 wrote: my meaning of "include only what is utilized" refers only to C++ #include declaration
Ok but then what is the point?
Generally these sorts of questions involve figuring out how to minimize what is delivered to production.
The delivery must include everything that is needed.
|
|
|
|
|
|
However not a new problem. And many solutions have been tried.
At a minimum it requires caches, dependency trees, and update times. But in my experience they always seem to fail on larger projects which is exactly where the value comes from.
The correct solution however lies in designing the application in the first place such that dependencies are not propagated throughout. That however is not a technological solution.
|
|
|
|
|
I got this .Ignore file [^]off of Git, but I'm still ending up with all kinds of unwanted files in my unstaged. I'm new to setting this up. I'm sure I've done something wrong. Can someone shed some light?
## Ignore Visual Studio temporary files, build results, and
<h2>files generated by popular Visual Studio add-ons.</h2>
<h1>#</h1>
<h2>Get latest from <a href="https://github.com/github/gitignore/blob/main/VisualStudio.gitignore"><a href="https://github.com/github/gitignore/blob/main/VisualStudio.gitignore">https:
<h1>User-specific files</h1>
*.rsuser
*.suo
*.user
*.userosscache
*.sln.docstates
<h1>User-specific files (MonoDevelop/Xamarin Studio)</h1>
*.userprefs
<h1>Mono auto generated files</h1>
mono_crash.*
<h1>Build results</h1>
[Dd]ebug/
[Dd]ebugPublic/
[Rr]elease/
[Rr]eleases/
x64/
x86/
[Ww][Ii][Nn]32/
[Aa][Rr][Mm]/
[Aa][Rr][Mm]64/
bld/
[Bb]in/
[Oo]bj/
[Ll]og/
[Ll]ogs/
<h1>Visual Studio 2015/2017 cache/options directory</h1>
.vs/
<h1>Uncomment if you have tasks that create the project's static files in wwwroot</h1>
<h1>wwwroot/</h1>
<h1>Visual Studio 2017 auto generated files</h1>
Generated\ Files/
<h1>MSTest test Results</h1>
[Tt]est[Rr]esult*/
[Bb]uild[Ll]og.*
<h1>NUnit</h1>
.VisualState.xml
TestResult.xml
nunit-.xml
<h1>Build Results of an ATL Project</h1>
[Dd]ebugPS/
[Rr]eleasePS/
dlldata.c
<h1>Benchmark Results</h1>
BenchmarkDotNet.Artifacts/
<h1>.NET Core</h1>
project.lock.json
project.fragment.lock.json
artifacts/
<h1>ASP.NET Scaffolding</h1>
ScaffoldingReadMe.txt
<h1>StyleCop</h1>
StyleCopReport.xml
<h1>Files built by Visual Studio</h1>
*_i.c
*_p.c
*_h.h
*.ilk
*.meta
*.obj
*.iobj
*.pch
*.pdb
*.ipdb
*.pgc
*.pgd
*.rsp
*.sbr
*.tlb
*.tli
*.tlh
*.tmp
*.tmp_proj
*_wpftmp.csproj
*.log
*.tlog
*.vspscc
*.vssscc
.builds
*.pidb
*.svclog
*.scc
<h1>Chutzpah Test files</h1>
_Chutzpah*
<h1>Visual C++ cache files</h1>
ipch/
*.aps
*.ncb
*.opendb
*.opensdf
*.sdf
*.cachefile
*.VC.db
*.VC.VC.opendb
<h1>Visual Studio profiler</h1>
*.psess
*.vsp
*.vspx
*.sap
<h1>Visual Studio Trace Files</h1>
*.e2e
<h1>TFS 2012 Local Workspace</h1>
$tf/
<h1>Guidance Automation Toolkit</h1>
*.gpState
<h1>ReSharper is a .NET coding add-in</h1>
_ReSharper*/
*.[Rr]e[Ss]harper
*.DotSettings.user
<h1>TeamCity is a build add-in</h1>
_TeamCity*
<h1>DotCover is a Code Coverage Tool</h1>
*.dotCover
<h1>AxoCover is a Code Coverage Tool</h1>
.axoCover/*
!.axoCover/settings.json
<h1>Coverlet is a free, cross platform Code Coverage Tool</h1>
coverage*.json
coverage*.xml
coverage*.info
<h1>Visual Studio code coverage results</h1>
*.coverage
*.coveragexml
<h1>NCrunch</h1>
NCrunch*
.crunch.local.xml
nCrunchTemp_*
<h1>MightyMoose</h1>
.mm.
AutoTest.Net/
<h1>Web workbench (sass)</h1>
.sass-cache/
<h1>Installshield output folder</h1>
[Ee]xpress/
<h1>DocProject is a documentation generator add-in</h1>
DocProject/buildhelp/
DocProject/Help/.HxT
DocProject/Help/.HxC
DocProject/Help/.hhc
DocProject/Help/.hhk
DocProject/Help/*.hhp
DocProject/Help/Html2
DocProject/Help/html
<h1>Click-Once directory</h1>
publish/
<h1>Publish Web Output</h1>
*.[Pp]ublish.xml
*.azurePubxml
<h1>Note: Comment the next line if you want to checkin your web deploy settings,</h1>
<h1>but database connection strings (with potential passwords) will be unencrypted</h1>
*.pubxml
*.publishproj
<h1>Microsoft Azure Web App publish settings. Comment the next line if you want to</h1>
<h1>checkin your Azure Web App publish settings, but sensitive information contained</h1>
<h1>in these scripts will be unencrypted</h1>
PublishScripts/
<h1>NuGet Packages</h1>
*.nupkg
<h1>NuGet Symbol Packages</h1>
*.snupkg
<h1>The packages folder can be ignored because of Package Restore</h1>
**/[Pp]ackages/*
<h1>except build/, which is used as an MSBuild target.</h1>
!**/[Pp]ackages/build/
<h1>Uncomment if necessary however generally it will be regenerated when needed</h1>
<h1>!**/[Pp]ackages/repositories.config</h1>
<h1>NuGet v3's project.json files produces more ignorable files</h1>
*.nuget.props
*.nuget.targets
<h1>Microsoft Azure Build Output</h1>
csx/
*.build.csdef
<h1>Microsoft Azure Emulator</h1>
ecf/
rcf/
<h1>Windows Store app package directories and files</h1>
AppPackages/
BundleArtifacts/
Package.StoreAssociation.xml
_pkginfo.txt
*.appx
*.appxbundle
*.appxupload
<h1>Visual Studio cache files</h1>
<h1>files ending in .cache can be ignored</h1>
*.[Cc]ache
<h1>but keep track of directories ending in .cache</h1>
!?*.[Cc]ache/
<h1>Others</h1>
ClientBin/
~$*
*~
*.dbmdl
*.dbproj.schemaview
*.jfm
*.pfx
*.publishsettings
orleans.codegen.cs
<h1>Including strong name files can present a security risk</h1>
<h1>(<a href="https://github.com/github/gitignore/pull/2483#issue-259490424"><a href="https://github.com/github/gitignore/pull/2483#issue-259490424">https:
<h1>*.snk</h1>
<h1>Since there are multiple workflows, uncomment next line to ignore bower_components</h1>
<h1>(<a href="https://github.com/github/gitignore/pull/1529#issuecomment-104372622"><a href="https://github.com/github/gitignore/pull/1529#issuecomment-104372622">https:
<h1>bower_components/</h1>
<h1>RIA/Silverlight projects</h1>
Generated_Code/
<h1>Backup & report files from converting an old project file</h1>
<h1>to a newer Visual Studio version. Backup files are not needed,</h1>
<h1>because we have git ;-)</h1>
_UpgradeReport_Files/
Backup*/
UpgradeLog*.XML
UpgradeLog*.htm
ServiceFabricBackup/
*.rptproj.bak
<h1>SQL Server files</h1>
*.mdf
*.ldf
*.ndf
<h1>Business Intelligence projects</h1>
*.rdl.data
*.bim.layout
.bim_.settings
*.rptproj.rsuser
*- [Bb]ackup.rdl
*- [Bb]ackup ([0-9]).rdl
*- [Bb]ackup ([0-9][0-9]).rdl
<h1>Microsoft Fakes</h1>
FakesAssemblies/
<h1>GhostDoc plugin setting file</h1>
*.GhostDoc.xml
<h1>Node.js Tools for Visual Studio</h1>
.ntvs_analysis.dat
node_modules/
<h1>Visual Studio 6 build log</h1>
*.plg
<h1>Visual Studio 6 workspace options file</h1>
*.opt
<h1>Visual Studio 6 auto-generated workspace file (contains which files were open etc.)</h1>
*.vbw
<h1>Visual Studio 6 auto-generated project file (contains which files were open etc.)</h1>
*.vbp
<h1>Visual Studio 6 workspace and project file (working project files containing files to include in project)</h1>
*.dsw
*.dsp
<h1>Visual Studio 6 technical files</h1>
*.ncb
*.aps
<h1>Visual Studio LightSwitch build output</h1>
**/.HTMLClient/GeneratedArtifacts
*/.DesktopClient/GeneratedArtifacts
*/.DesktopClient/ModelManifest.xml
*/.Server/GeneratedArtifacts
*
If it's not broken, fix it until it is.
Everything makes sense in someone's mind.
Ya can't fix stupid.
|
|
|
|
|
Is the first square in your capture the “end of file” character?
What happens if you type/cat the file?
|
|
|
|
|
|
|
Perhaps this is relevant - if they are not filtered after commit, perhaps there is a mismatch between global git configuration and a local git configuration (?) Quote: Global Git ignore rules
In addition, you can define global Git ignore patterns for all repositories on your local system by setting the Git core.excludesFile property. You'll have to create this file .gitignore file - ignoring files in Git | Atlassian Git Tutorial
|
|
|
|
|
Might help to specify the exact files (some of them) which you do not expect are showing up.
|
|
|
|
|
I have mountains of stuff, lots of it is software like old versions of Visual Studio and older IDEs, along with books for learning a number of long obsolete tools, like MFC and TurboPascal. Many years ago, when it was impossible to afford any MS product on a normal income, a member here generously sent me a version of VS that I could never otherwise purchase, and got me up and running again. I would hate to throw this stuff away and later learn that there was someone here who could really use it, either to learn, or to support an older product. But I have no idea how to find anyone who might need what I'm about to toss. Can someone make a suggestion? I'm sure there are others here in my same predicament.
Will Rogers never met me.
|
|
|
|
|
Storage is so cheap these days that I don't bother to throw away stuff. Just file it somewhere. I never find it when I need it but that's OK, I always find it the next day
Mircea
|
|
|
|
|
ditto
"A little time, a little trouble, your better day"
Badfinger
|
|
|
|
|
There is no such thing as cheap storage. This is physical product, not software images. I have an entire room that I cannot traverse on foot because of the piles of books, papers and CDs. Oh, and there's a few guns in there, too, along with a bunch of ammo. I have a 45' shipping container sitting in the middle of a 20 acre parcel of land filled to the brim with "stuff" that I can't even get to. I had to bury the doors with my tractor to keep the tweakers from breaking into it when I'm away. Now I have to hide my tractor to keep them from stealing it. In my back yard, I have a 10' x 10' shed full of containers of books - mostly computer related. This has got to end, but I don't want to trash anything any of my friends here can use. It's a quandry...
Will Rogers never met me.
|
|
|
|
|
I see! Your problem is orders of magnitude larger than mine.
For CD's I made them all ISO images and put them on a NAS. I have 16TB available so I could store a bit more than 20000 CD's and I've never had anywhere near that number. Floppies and zip disks (remember those?) had the same fate. Good thing I did it before my zip drive died. Most documents have also been scanned as well as some books that I was particularly attached to.
If you make a list of what you have, count me among those interested. Good luck!
Mircea
|
|
|
|
|
Mircea Neacsu wrote: If you make a list of what you have, count me among those interested. Good luck!
I'll put you on the list, Mircea. This won't be soon, but it's something I have to do! I wonder if my copy of ProLog for DOS will run on Windows 11? AI is starting to look big!
Will Rogers never met me.
|
|
|
|
|
Roger Wright wrote: ProLog for DOS
I remember this from my first year in the college. We had to create a maze and save the Little Mermaid using a predicate language. I feel old now.
Advertise here – minimum three posts per day are guaranteed.
|
|
|
|