3 ms·
I use Thunderbird for my email. Its behavior shows it is a multithreaded program. But often, the mouse and keyboard will freeze and it becomes unresponsive for
by WalterBright 4y ago
I use Thunderbird for my email. Its behavior shows it is a multithreaded program.
But often, the mouse and keyboard will freeze and it becomes unresponsive for several seconds. This is indicative of suboptimal partitioning of the tasks into threads. The highest priority thread should be responding to user input.
Heck, back in the 1970s, I designed and built a single board computer that was to be a glass tty. There was no way to get that 6800 uP to update the screen fast enough to keep up with characters arriving at 9600 baud.
The solution was, whenever the user hit a key, to abandon updating the screen and process the character. Once that process was complete, and there were no more keys in the input, the screen updating was restarted.
It worked out great. You simply never noticed this was happening, and you always got crisp response.
I did the same thing for the MicroEmacs text editor on the IBM PC. If I hadn't, the editor would lose input and/or have noticeable lags refreshing the screen.
P.S. The importance of not losing input was necessitated by using ttys to transfer files across the phone lines and serial ports. You also couldn't touch type if the tty lost key input.
P.P.S. The Chrome browser that I use also has problems with freezing on keyboard input.
- spacechild1 4y agoFor me the UI hangs whenever Thunderbird downloads new messages. It seems as if they are doing network I/O on the UI thread - which can't be true...
- WalterBright 4y agoI learned not to touch the keyboard when TB was downloading new messages and running filters. Otherwise it would randomly corrupt the message file, and I'd lose it all. Yes, I filed a bug report with TB. No, they never found the problem.
- jiggawatts 4y agoI stopped using Thunderbird a long time ago because it had a “feature” that would erase all of your email if it detected that your profile was corrupt… … but it has a habit of corrupting profile files on shutdown.
- MichaelZuo 4y agoIf all other explanations fail then even the least likeliest explanation is very likely true.
- fuzzfactor 4y agoAfter all recommended approaches have been tried unsuccessfully, certainly the solution will be something that is not recommended.
- ClumsyPilot 4y agoI stopped using thunderbird for this reason
- dekhn 4y agoeven by mid-80s, if you used the naive serial routines built into the Apple IIe you couldn't do 1200bps- 300bps worked. Professional terminal programs used interrupt and buffers to capture incoming bytes while the screen scrolled (https://sites.google.com/site/drjohnbmatthews/apple2/ssc?pli=1 https://sites.google.com/site/drjohnbmatthews/apple2/ssc?pli...). At least that's what the author of ProTERM told me when I was a kid and I asked how it worked. It sounded pretty exotic at the time but now I work with low-level hardware... $5 chip that can do 2Mbps over serial.
- WalterBright 4y agoYup, ISRs are the solution for 6800 and 6502 chips. Data I/O's LogicPak (powered by a 6502) used polling, and would now and then lose data because of that. I advised the engineer working on it to just write an ISR. Months went by, while he was convinced he could make the polling work. Finally, the manager dropped by and asked if I could just fix it. In a couple hours had it fixed with an ISR. No more problems.
- bcrl 4y agoThe Amiga's built in serial port was particularly atrocious as the hardware could only buffer 1 character at a time. This meant that it did not work particularly well at baud rates above 9600. Combined with the CPU being starved from accessing RAM when running in hires 16 colour modes (used when emulating ANSI "graphics" common at BBSes back then), this made it rather unpleasant as a terminal emulator.
- zozbot234 4y agoThe Amiga supported both chip and fast RAM, precisely to solve the problem you're talking about. What you mention here was at most an issue with your particular machine, not a limit of the platform itself.
- bcrl 4y agoNo, that doesn't solve the problem -- I had a few megabytes of fast RAM, and it still sucked. The chipset bus is completely contended in 4 bitplane high res graphics in OCS/ECS, so any attempt to access the serial port registers is blocked until the horizontal blanking interval (as is chip or slow RAM). The faster and wider data path in the AGA chipset improved this substantially, but that data path was only used for video DMA, not for the blitter or other chipset register accesses. The only real solution was to use an aftermarket serial port card that wasn't on the chipset bus and used a real UART like the 16550 that had a 16 byte FIFO.
- nix23 4y agoI can crash Linux(all tested distros >5 for at leat 3 years) and FreeBSD reliable with Thunderbird, it's a terrible application and a statement for GUI-oss-applications....pure shame.... Edit: and no, not with root or a "wheel"-User
- redeeman 4y agoplease provide a step by step guide on how to do this
- WalterBright 4y agoNot with TB specifically, but some years ago I was able to consistently crash both Windows and Linux by filling up the disk drive nearly to the brim, and then running various applications. It seems that not many programs consistently check disk writes for failures, or if they do, they don't shut down gracefully.
- nix23 4y agoHaving 1000's of Mails in TB (maildir or mailbox) in at least 5 accounts, then right click on a big folder and click "repair", when it starts to login (before synchronization of header starts) remove the Ethernet cable (no other connection shall be active) click around in TB in a frenzy manner (go "offline", try to repair again, open menus etc), and see your TB freeze then your X11 session, sometimes if your lucky the system crashes (works best with intel GPU's..the crash i mean). The slower your imap the faster the freeze, Gmail works best.
- BenjiWiebe 4y agoWorks fine for me, for the last 10+ years. Fedora and Thunderbird.
- deterministic 4y agoIt just shows that Thunderbird has room for improvement when it comes to how it uses multi-threading. You always want the UI thread to be non-blocking and react instantly when a user does something. Most games (for example) do this really well.