Performance Profiler - A first attempt

Page 6/7
1 | 2 | 3 | 4 | 5 | | 7

By Bengalack

Master (135)

Bengalack's picture

20-03-2020, 21:50

Grauw wrote:

See this code snippet in tiletile for a more elaborate example.

How does this work exactly? Are there some kind of magic to the name "openmsx.tcl", so it runs automatically somehow? Can't get this to work. Don't know how to get it executed. Don't know where to put it oO

I would appreciate a tip or two Smile

By Manuel

Ascended (16692)

Manuel's picture

20-03-2020, 22:28

Bengalack: if you put a file with extension .tcl in the share/scripts folder of openMSX (either the system folder or your own), it will be automatically loaded at openMSX startup. But you can also use the Tcl command source to load a Tcl script manually. You can do this in the openMSX console (open with F10), which is basically a Tcl shell.

By salutte

Expert (68)

salutte's picture

21-03-2020, 13:33

You also need a fairly recent version of openMSX (I had to compile one, in order to support the "-once" parameter).
Setting up your own break points is currently also pretty tricky, I was working at the beginning of the week on an "auto detection" of sections, to make it easier, but the complexity is growing at the same time as the capabilities.

I'll try to put more time on it this weekend, I had a pretty busy week and could not push it forward.

By Bengalack

Master (135)

Bengalack's picture

22-03-2020, 13:16

Thanks! I have a certain workflow going now. Great Smile

So I named the script "openmsx.tcl". If I have one in the scripts-folder and one in the "current" folder - openmsx prioritizes the current folder.

The great thing now, is that I am able to run the script with F10 + key up + ENTER (normally, after having typed "source openmsx.tcl" once).

I have compiled my own version of openmsx to support the -once flag. But it does not seem to work. The symbol/address I put in the brackets (like "Scene_Run" below) does not seem to trigger.

debug set_bp -once [symbol Scene_Run] {[my_slot_pc]} {

But it does not matter much, it seems to work fine by just having these:

profile::section_scope_bp frame [symbol < symbol name >]
profile::section_scope_bp < caption > [symbol < symbol name >]
...

What does not seem to work as expected though is the throttle command inside scripts:

set throttle on|off

Seems like pretty random to get this to work in scripts. With F9 it always works though. I have wanted to put it in the startup-script ("openmsx -script xxx"), as speedy startup is kind of neat. Worked last week, when I had a bunch of other commands there. I have cleaned up the script now, and now it doesn't work anymore :-(

Also, openmsx built 7. March from master:
* running the my version of openmsx complains a lot about shader-linking in the console and window wont show using catapult before you toggle the scale-factor, but these things can be ignored/avoided.
* the menu does not work

Should I report these things somewhere?

By Bengalack

Master (135)

Bengalack's picture

22-03-2020, 14:20

Bengalack wrote:

Also, openmsx built 7. March from master:

windows x64. Built using msdev on a windows 10 home setup.

By Manuel

Ascended (16692)

Manuel's picture

22-03-2020, 19:07

Do you see any errors somewhere? Does it work for other people? (It does work for me.)

By Bengalack

Master (135)

Bengalack's picture

22-03-2020, 19:58

Here's a mashup of screens.

Here's info from the compiler of my version of openmsx:

Microsoft Visual Studio Community 2019
Version 16.4.4
VisualStudio.16.Release/16.4.4+29728.190
Microsoft .NET Framework
Version 4.8.03752

Installed Version: Community

Visual C++ 2019   00435-60000-00000-AA850
Microsoft Visual C++ 2019

ASP.NET and Web Tools 2019   16.4.460.23317
ASP.NET and Web Tools 2019

Azure App Service Tools v3.0.0   16.4.460.23317
Azure App Service Tools v3.0.0

C# Tools   3.4.1-beta4-19614-01+165046097562cfe65b09c2e9a9d8f7cd88526f2c
C# components used in the IDE. Depending on your project type and settings, a different version of the compiler may be used.

Common Azure Tools   1.10
Provides common services for use by Azure Mobile Services and Microsoft Azure Tools.

Cookiecutter   16.4.19310.1
Provides tools for finding, instantiating and customizing templates in cookiecutter format.

IntelliCode Extension   1.0
IntelliCode Visual Studio Extension Detailed Info

Microsoft Azure Tools   2.9
Microsoft Azure Tools for Microsoft Visual Studio 2019 - v2.9.21016.1

Microsoft JVM Debugger   1.0
Provides support for connecting the Visual Studio debugger to JDWP compatible Java Virtual Machines

Microsoft MI-Based Debugger   1.0
Provides support for connecting Visual Studio to MI compatible debuggers

Microsoft Visual C++ Wizards   1.0
Microsoft Visual C++ Wizards

Microsoft Visual Studio VC Package   1.0
Microsoft Visual Studio VC Package

NuGet Package Manager   5.4.0
NuGet Package Manager in Visual Studio. For more information about NuGet, visit <a href="https://docs.nuget.org/" title="https://docs.nuget.org/">https://docs.nuget.org/</a>

ProjectServicesPackage Extension   1.0
ProjectServicesPackage Visual Studio Extension Detailed Info

Python   16.4.19310.1
Provides IntelliSense, projects, templates, debugging, interactive windows, and other support for Python developers.

Python - Conda support   16.4.19310.1
Conda support for Python projects.

Python - Django support   16.4.19310.1
Provides templates and integration for the Django web framework.

Python - IronPython support   16.4.19310.1
Provides templates and integration for IronPython-based projects.

Python - Profiling support   16.4.19310.1
Profiling support for Python projects.

Test Adapter for Boost.Test   1.0
Enables Visual Studio's testing tools with unit tests written for Boost.Test.  The use terms and Third Party Notices are available in the extension installation directory.

Test Adapter for Google Test   1.0
Enables Visual Studio's testing tools with unit tests written for Google Test.  The use terms and Third Party Notices are available in the extension installation directory.

TypeScript Tools   16.0.11031.2001
TypeScript Tools for Microsoft Visual Studio

Visual Basic Tools   3.4.1-beta4-19614-01+165046097562cfe65b09c2e9a9d8f7cd88526f2c
Visual Basic components used in the IDE. Depending on your project type and settings, a different version of the compiler may be used.

Visual Studio Code Debug Adapter Host Package   1.0
Interop layer for hosting Visual Studio Code debug adapters in Visual Studio

Visual Studio Tools for CMake   1.0
Visual Studio Tools for CMake

Visual Studio Tools for CMake   1.0
Visual Studio Tools for CMake

By Bengalack

Master (135)

Bengalack's picture

22-03-2020, 19:59

Renderer: SDLGL-PP produces the warnings. Not SDL. But their behavior is the same.

By Manuel

Ascended (16692)

Manuel's picture

22-03-2020, 21:57

Yes, SDLGL-PP uses shaders, SDL does not. These are harmless deprecation warnings, but I created an issue for it in our tracker: https://github.com/openMSX/openMSX/issues/1236

Looking from the screenshot (the WORLD_92 error), you have probably some scripts of older openMSX versions in your openMSX user directory. Please remove them completely and then see whether things work better.

By Bengalack

Master (135)

Bengalack's picture

23-03-2020, 00:54

Thank you!. The menu works now. Also, I had old files under share, including shaders, so the shader-warnings are now gone. Things work super smooth now. When I start openmsx from dos it shows up as expected, but when starting from catapult the openmsx-window will not start before I have fiddled with the general rendering controls. But I'm usually not using catapult, so it is not a problem.

My "install" is the custom build of openmsx with share-folder copied in as a subfolder. Not sure if this was the proper way to do it oO

Page 6/7
1 | 2 | 3 | 4 | 5 | | 7