Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Simon Marchi via Gdb <gdb@sourceware.org>
To: Basile Starynkevitch <basile@starynkevitch.net>, gdb@sourceware.org
Subject: Re: GDB 17.1 / Linux setting limits for the debugged process?
Date: Mon, 26 Jan 2026 10:49:28 -0500	[thread overview]
Message-ID: <91e699c1-53ea-4c7f-85b9-7d4295490846@simark.ca> (raw)
In-Reply-To: <89ca6f862b1db1e07138c858204ed170cf820ff1.camel@starynkevitch.net>

On 1/26/26 9:08 AM, Basile Starynkevitch wrote:
> Hello all,
> 
> (this is motivated by https://github.com/RefPerSys/RefPerSys/issues/30 - a bug in a GPL licensed inference engine project coded in C++)
> 
> Using GDB 17.1 on an open source software compiled by GCC 16 snapshot (or latest GCC 15) on a Debian/Linux desktop (or laptop), 
> how can I set limits (in the https://man7.org/linux/man-pages/man2/getrlimit.2.html sense, for elapsed CPU time limit)
> on the debugged process, but not on the GDB 17.1 debugging process?

Try to set "prlimit" as the exec-wrapper:

(gdb) set exec-wrapper prlimit --cpu=1234
(gdb) run

Simon

      reply	other threads:[~2026-01-26 15:50 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-26 14:08 Basile Starynkevitch
2026-01-26 15:49 ` Simon Marchi via Gdb [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=91e699c1-53ea-4c7f-85b9-7d4295490846@simark.ca \
    --to=gdb@sourceware.org \
    --cc=basile@starynkevitch.net \
    --cc=simark@simark.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox