[Haskell-cafe] ANNOUNCE: Haskell Pdf Presenter (hpdfp) 0.2.2

Michael D. Adams mdmkolbe at gmail.com
Thu Nov 14 08:14:12 UTC 2013


When the program is doing background rendering, it will go to 100% CPU
time, but once the background rendering completes, it should settle
down to almost no CPU usage at all (my task manager literally shows 0%
CPU once pre-rending completes).

Does this high CPU usage happen even when you don't load a PDF?

After loading a PDF, there will be a small progress bar that races
across the bottom of the presenter window.  This represents the
pre-rendering process.  Does the CPU usage lower after that process
completes?  (If you need to run the experiment a few times, note that
pressing Ctrl-R will flush the cache and re-trigger pre-rending.)

If what you are seeing isn't just the background rendering, then the
first place I would look is to see if the render thread is properly
switching from renderThreadSoon (which burns up CPU) to
renderThreadDelayed (which has a 100ms delay to avoid burning up CPU).
 You might also try changing the 100ms delay in renderThreadDelayed
(HaskellPdfPresenter.hs line 932) to something larger like 1000ms.

What operating system, compiler and package versions are you using?

If you have any other clues, figure out what is going on, or if there
is any way I can help you solve this, please let me know.

On Wed, Nov 13, 2013 at 1:57 PM, Niklas Hambüchen <mail at nh2.me> wrote:
> That is great, I've been interested in that program since your POPL
> talk.
>
> One problem I've had with it so far:
> It takes 100% CPU time when idle, which makes my laptop go quite hot.
> Any idea why that could be?
>
> On Wed 13 Nov 2013 18:16:48 GMT, Michael D. Adams wrote:
>> ANNOUNCE: Haskell Pdf Presenter (hpdfp) 0.2.2
>>
>> I'm pleased to announce the first public release of the Haskell Pdf
>> Presenter (hpdfp).
>>
>> Project home page:
>>   http://michaeldadams.org/projects/haskell-pdf-presenter/
>>
>> Project on Hackage:
>>   http://hackage.haskell.org/package/haskell-pdf-presenter/
>>
>> Project repository:
>>   http://michaeldadams.org/repos-pub/hg/haskell-pdf-presenter/
>>
>> What it is
>> ==========
>> The Haskell Pdf Presenter (hpdfp) is a tool for presenting PDF-based
>> slide shows.  For example, as a presenter, I like to see the next slide
>> before it is shown to the audience as well as how much allotted time
>> remains.  I was never quite satisfied with the existing tools for this,
>> so I wrote my own and hpdfp is the result.
>>
>> Though I originally wrote it for my own use, the tool has matured over
>> time, and I now wish to share it with others.  Aside from being a
>> useful tool, I think hpdfp is a good example of elegance and economy
>> in program design.  Despite being only a thousand lines long, this
>> program is full of features that may not be obvious at first glance so
>> please be sure to look at the available help.
>>
>> Status
>> ======
>> I've been using this tool in my own talks for over a year now, and
>> it is fairly stable and feature complete.  I've only tested it on
>> Ubuntu so I don't know if it ports to other platforms.  I'd love to
>> hear any field reports about how it runs on other platforms.
>>
>> Future Directions
>> =================
>> I have a long TODO list of ideas I may implement in the future, but
>> most development has been driven by the practical considerations that
>> I discover as I use the tool.  If you have a use case for a particular
>> feature, please let me know.
>>
>> ================
>>
>> Feature requests, bug reports, suggestions or feedback as well as
>> contributions to the documentation or implementation are most welcome.
>>
>> Michael D. Adams
>> _______________________________________________
>> Haskell-Cafe mailing list
>> Haskell-Cafe at haskell.org
>> http://www.haskell.org/mailman/listinfo/haskell-cafe


More information about the Haskell-Cafe mailing list