Your message dated Sun, 21 Oct 2018 09:13:15 +0200
with message-id <[email protected]>
and subject line Re: Bug#905160: Disable expression tree simplification via 
parser.conf
has caused the Debian Bug report #905160,
regarding Disable expression tree simplification via parser.conf
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
905160: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=905160
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: apparmor
Version: 2.13-6
Severity: normal
X-Debbugs-Cc: Jamie Strandboge <[email protected]>

See discussion that starts on
https://salsa.debian.org/apparmor-team/apparmor/merge_requests/9#note_35068

The attached patch implements the solution Jamie and I agreed on but
it breaks the autopkgtests:

simple.pl (Wstat: 768 Tests: 71577 Failed: 3)
  Failed tests:  71092, 71482-71483
  TODO passed:   71447, 71458-71459, 71493, 71576
  Non-zero exit status: 3

… so more work is needed here, to adjust the test suite to the
config change we want to apply.

Note that the tests do pass when they're run on a system where
/etc/apparmor/parser.conf does *not* contain
Optimize=no-expr-simplify.

>From a9d5816aed4a8b2dfa1e9505ef862cd9289b370f Mon Sep 17 00:00:00 2001
From: intrigeri <[email protected]>
Date: Wed, 1 Aug 2018 00:51:13 +0000
Subject: [PATCH 1/2] parser.conf: turn off expression tree simplification,
 that makes performance much worse in some cases.

---
 ...n-off-expression-tree-simplification.patch | 26 +++++++++++++++++++
 debian/patches/series                         |  1 +
 2 files changed, 27 insertions(+)
 create mode 100644 debian/patches/debian/Turn-off-expression-tree-simplification.patch

diff --git a/debian/patches/debian/Turn-off-expression-tree-simplification.patch b/debian/patches/debian/Turn-off-expression-tree-simplification.patch
new file mode 100644
index 000000000..a85abffd0
--- /dev/null
+++ b/debian/patches/debian/Turn-off-expression-tree-simplification.patch
@@ -0,0 +1,26 @@
+From: intrigeri <[email protected]>
+Date: Wed, 1 Aug 2018 00:45:18 +0000
+Subject: Turn off expression tree simplification.
+
+As discussed on
+https://salsa.debian.org/apparmor-team/apparmor/merge_requests/9, in quite a few
+situations expression tree simplification makes compilation dramatically slower.
+In one single pathological case (Evince profile) it improves things but affected
+systems, i.e. desktop systems, are more beefy and should cope with that.
+---
+ parser/parser.conf | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/parser/parser.conf b/parser/parser.conf
+index 641cf1d..769de83 100644
+--- a/parser/parser.conf
++++ b/parser/parser.conf
+@@ -51,7 +51,7 @@
+ #equiv
+ 
+ ## Turn off expr tree simplification
+-#Optimize=no-expr-simplify
++Optimize=no-expr-simplify
+ 
+ ## Turn off DFA minimization
+ #Optimize=no-minimize
diff --git a/debian/patches/series b/debian/patches/series
index ff280ade1..99732f2e8 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -16,5 +16,6 @@ debian/allow-access-to-ibus-socket.patch
 debian/non-linux.patch
 debian/Add-snapd-profiles-directory-support-to-profiles_names_li.patch
 debian/Move-the-cache-to-var-cache.patch
+debian/Turn-off-expression-tree-simplification.patch
 debian-only/pin-feature-set.patch
 debian-only/aa-notify-point-to-Debian-documentation.patch
-- 
2.18.0


--- End Message ---
--- Begin Message ---
intrigeri:
> Control: retitle -1 Disable expression tree simplification via parser.conf

> Most likely 2.13-7 will disable expression tree simplification
> via debian/lib/apparmor/functions, as a temporary workaround:
> https://salsa.debian.org/apparmor-team/apparmor/merge_requests/9/diffs?commit_id=97e62e7b06f7e759257eeb3aa62bdca8afb71dac

This is indeed what happened.

> This bug report is about replacing this temporary workaround with
> a proper solution :)

Thinking about it a bit harder, I don't think anymore that applying
this tweak via parser.conf is a better solution: it won't work for
anyone who has modified that file locally and skips merging our
updates, be it when we apply the tweak or when we revert it (once the
expression tree simplification implementation is fixed).

A better solution was proposed on
https://gitlab.com/apparmor/apparmor/merge_requests/246, which should
avoid the need to disable expression tree simplification in the first
place, and thus no such packaging tweak won't be needed ⇒ closing.

Cheers,
-- 
intrigeri

--- End Message ---

Reply via email to