From: Martin Walch <walch.martin@web.de>
To: Michal Marek <mmarek@suse.cz>
Cc: linux-kbuild@vger.kernel.org
Subject: Re: [PATCH v3] Kconfig: Remove bad inference rules expr_eliminate_dups2()
Date: Mon, 18 May 2015 11:38:47 +0200 [thread overview]
Message-ID: <5729946.JOCDOEaf0S@tacticalops> (raw)
In-Reply-To: <55599663.6080203@suse.cz>
On Monday 18 May 2015 15:36:03 Michal Marek wrote:
> Are you able to construct a testcase that triggers this bug? I haven't
> been successful:
> [..]
> config TEST1
> def_tristate (FOO || BAR) && (!FOO && !BAR)
This does not trigger the bug, because expr_eliminate_dups is only applied
to dependencies, but not to the expressions of default values.
I modified your example a bit, so that the bug becomes apparent:
config MODULES
def_bool y
option modules
config FOO
def_tristate m
config BAR
def_tristate m
config TEST1
def_tristate y
depends on (FOO || BAR) && (!FOO && !BAR)
if TEST1 = n
comment "TEST1 broken"
endif
config TEST2
def_tristate y
depends on (FOO && BAR) || (!FOO || !BAR)
if TEST2 = y
comment "TEST2 broken"
endif
config TEST3
def_tristate y
depends on m && !m
if TEST3 = n
comment "TEST3 broken"
endif
As you can see, I also added a third symbol TEST3 with a line
> depends on m && !m
This case is special: m && !m expands to (m && MODULES) && !(m && MODULES),
then it is transformed into (m && MODULES) && (!m || !MODULES), and finally
due to the bug it is replaced with n.
Regards,
Martin Walch
--
next prev parent reply other threads:[~2015-05-18 9:38 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-17 2:14 [PATCH v3] Kconfig: Remove bad inference rules expr_eliminate_dups2() Martin Walch
2015-05-18 7:36 ` Michal Marek
2015-05-18 9:38 ` Martin Walch [this message]
2015-05-21 6:39 ` Michal Marek
2015-05-22 11:41 ` [PATCH v4] " Martin Walch
2015-05-25 8:05 ` Michal Marek
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=5729946.JOCDOEaf0S@tacticalops \
--to=walch.martin@web.de \
--cc=linux-kbuild@vger.kernel.org \
--cc=mmarek@suse.cz \
/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