From: Jacob Lifshay Date: Thu, 9 Dec 2021 04:00:45 +0000 (-0800) Subject: add CommonPipeSpec.__getattr__ to forward attributes from parent_pspec X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ffe23c44be18661ad5d7682f41a702965283e84b;p=soc.git add CommonPipeSpec.__getattr__ to forward attributes from parent_pspec replaces CommonPipeSpec.draft_bitmanip --- diff --git a/src/soc/fu/pipe_data.py b/src/soc/fu/pipe_data.py index d48cf4c3..dc17150c 100644 --- a/src/soc/fu/pipe_data.py +++ b/src/soc/fu/pipe_data.py @@ -81,9 +81,12 @@ class CommonPipeSpec: self.opkls = lambda _: self.opsubsetkls() self.op_wid = get_rec_width(self.opkls(None)) # hmm.. self.stage = None - self.draft_bitmanip = False self.parent_pspec = parent_pspec + # forward attributes from parent_pspec + def __getattr__(self, name): + return getattr(self.parent_pspec, name) + def get_pspec_draft_bitmanip(pspec): """ True if the draft bitmanip instructions are enabled in the provided