How resposive is the maxima plugin?

I tried using the maxima plugin but it is very unresponsive. Have a look at the video. Is anyone else facing the same issue?

Do you mean editing in a Maxima session? I guess it is related to the syntax highlighter.

Yes, I’m talking about editing in a Maxima session? Do you also notice the same unresponsiveness?

For me (TeXmacs 2.1.1 on Xubuntu 21.10) it is nicely responsive

I am facing a lot of issues with TeXmacs on arch: (1) high cpu usage, (2) pdf vector images displayed in low resolution because TeXmacs cannot find ghoscript on my system even though it is installed, (3) poor perfomance in beamer and sessions like maxima.

For the ghostscript problem, we have an issue to solve your problem: https://github.com/XmacsLabs/mogan/issues/294

There is the bench tool, under the Debug menu that you activate from the Tools menu (Debugging tool). I won’t be able to interpret the significance of the output of that menu, but it might help the developers who in turn might be able to help you.
You will be able to see the output of the bench tool if you launch TeXmacs from the terminal.

I already did that and posted the result in another thread I created some time ago, which shows that TeXmacs is using qt to convert the images and no ghostscript.

I have built different versions of TeXmacs from the aur and all of them have this problem. However, I have an old appimage (v. 2.1.1) that doesn’t have this issue, but it performs poorly on maxima and has a high cpu usage. I also have the latest appimage (v 2.1.2). That one has reasonable cpu usage, but it is very slow (and takes a while to load). I don’t understand why this amount of variability exists between versions. In case you’re wondering, I use a new ~/.TeXmacs directory when testing.

Hopefully the developers will be able to tell you what is happening.

I hope so. I write all my notes in texmacs. I’m enjoying the experience so much that I’m considering learning scheme. I just hope the performance can be improved and I don’t have to deal with this variability issue.

I find it surprising that you experience so much variability, indeed.
The AppImages do not pack gs; they call your distro’s gs. Your own builds of the same version should operate just the same, unless you apply some patches from aur which alter this.
Variations on cpu usage and maxima responsiveness between the two AppImages are also unexpected for me (I think no code was changed in these areas, but I could be wrong). In general AppImages are expected to startup slower than standard texmacs (Appimages first decompress their code to /tmp, and that should take a couple of seconds at most) but after that they should run the same way (including as fast) as a usual linux build (your own, or from a distro’s package).
Are you sure your system always has enough available RAM when performing your tests? Swapping could perhaps explain sluggishness and cpu usage.

As I mentioned previously, I am on arch linux. There are no official packages from the standard arch repositories. I get access to texmacs via either (1) compiling from the aur, (2) compiled binaries from this link. For some reason, the latest 2.1.2 version suffers from two things on my setup: (1) they are noticeably slower in both startup and typing (responsiveness). (2) they don’t use ghoscript to convert pdf vector graphics and so end up with a blurry mess. Luckily, I have an old 2.1.1 appimage that I am currently using. It is more responsive, converts images to pdf, but it uses more cpu when idle. This was until I tried to use maxima and got a terrible experience.

Here is a sample video of the typing feel on both versions. Please note that the video looks smoother than it is because I am recording in high fps to capture the lag.

@hamorabi, I think you are mixing in too many issues here. It causes confusion and makes it hard to sort things out. Let me try to set things straight.

In the first post in this thread, the video shows some lag while using keyboard autorepeat in a maxima session.

First, standard TeXmacs 2.1.x for linux cannot run external sessions, because of this bug. AFAIK, only my linux builds on the OpenSuse’s Open Build Service (including the AppImages) have a workaround patch that allow to have external sessions working in TeXmacs 2.1.x. Arch aur builds do not have that workaround, and yours neither, presumably.

Second, a couple of posts above, you say AppImage v2.1.1 performs poorly with maxima. However, when launching Maxima in any Appimage version I actually get the following error :

Maxima encountered a Lisp error:

Condition in LOAD [or a callee]: INTERNAL-SIMPLE-PARSE-ERROR: “/tmp/.mount_texmaci2TzHQ/usr//share/TeXmacs/plugins/maxima/lisp/texmacs-maxima.lisp” is not a valid pathname on host NIL

which prevents the maxima session from working in Appimages (even though they have the workaround).

Hence, the details you provide on aur builds, your own builds and AppImages are irrelevent for the maxima session issue this thread is supposed to be about, because none of these can run a maxima session, actually. Your fist video could only be made using the arch build from the Open Build Service and the “variability” you mention is not about this maxima issue. This makes reading the thread very confusing and misleading.

If I understand correctly, the main concern you express in your 2 videos is regarding texmacs’ display responsiveness while using keyboard autorepeat, either in Maxima sessions or in plain text input. You point to a difference between 2.1.1 and 2.1.2, the latter being less smooth, whatever the build you use. The level of lag seen in the videos has always more or less been present in TeXmacs and, from what I see in your videos, it by no means prevent using TeXmacs or interacting with Maxima. At most, it makes the experience slightly less pleasant. The developers are aware reaction time is critical and they always make sure it remains acceptable at normal typing speeds (Keyboard autorepeat is not normal typing).

Finally, your pdf and gs issue has its own thread that you recently revived. Let’s keep it over there.

1 Like

Sorry for bringing up many issues at once. If we ignore maxima for now, the current version of TeXmas (v 2.1.2) has way more lag compared to v.2.1.1.