Dehydra/Treehydra: remove Dehydra->Treehydra dep in Require

RESOLVED FIXED

Status

()

Core
Rewriting and Analysis
RESOLVED FIXED
10 years ago
10 years ago

People

(Reporter: dmandelin, Assigned: dmandelin)

Tracking

Trunk
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Assignee)

Description

10 years ago
My implementation of the pass option for the require builtin introduced a dependence of Dehydra on Treehydra. I thought it was just a bit ugly, but it causes real problems for the Mac port, because they don't have Treehydra at all yet.

I plan to fix the problem by making require table-driven, so that each tool can install its own function pointers into the table. The goal is to have direct dependences only of Treehydra on Dehydra.
(Assignee)

Updated

10 years ago
Blocks: 423898
(Assignee)

Comment 1

10 years ago
Created attachment 313700 [details] [diff] [review]
Fix, so to speak

Well, this fix isn't entirely nondisgusting, but I think it will work. A definitive fix awaits the multiplexing system. 

I included the work of bug 426893 inside this patch because it's needed to test this functionality (and, more to the point, because I was unaware that 426893 had been filed). Let me know if you want it split out, but I don't think it's a big deal.

Comment 2

10 years ago
Comment on attachment 313700 [details] [diff] [review]
Fix, so to speak

>diff -r 591ce7705222 test/Makefile
>--- a/test/Makefile	Fri Apr 04 12:49:27 2008 -0700
>+++ b/test/Makefile	Fri Apr 04 14:47:57 2008 -0700
>@@ -8,9 +8,12 @@ CXXFLAGS = $(PLUGINARG) -fplugin-arg=$(S
> 
> all: test.o assign.o typedef.o operator_new.o destr_order.o init.o virtual.o constructor.o types.o templ-spec.o constructor.o stack_fieldOf.o templ-simple.o longevity.o finalizers.o unit_tests
> 
>-# Treehydra unit tests
>+# Unit tests
> unit_tests:
>-	python unit_test_harness.py "$(CC1PLUS) -fplugin=../gcc_%s.so -o /dev/null -fplugin-arg=%s %s"
>+	python unit_test_harness.py both "$(CC1PLUS) -fplugin=../gcc_%s.so -o /dev/null -fplugin-arg=%s %s"
>+
>+dehydra_unit_tests:
>+	python unit_test_harness.py dehydra "$(CC1PLUS) -fplugin=../gcc_%s.so -o /dev/null -fplugin-arg=%s %s"
> 
> %.o: %.cc $(PLUGIN)
> 	$(CC1PLUS) $(CXXFLAGS) $< -o /dev/null

Careful here. Can't make both the default since treehydra isn't built by default. 
My recent commit added unit_tests to all: so this is bad.
(Assignee)

Comment 3

10 years ago
(In reply to comment #2)
> Careful here. Can't make both the default since treehydra isn't built by
> default. 
> My recent commit added unit_tests to all: so this is bad.
 
OK, I changed the 'all' line to run dehydra_unit_tests instead. Is that OK? 

I'd like to get this pushed because it changes the unit test harness design, making it bitrot every time the unit test harness script changes.

Comment 4

10 years ago
Don't worry for my permission on pushing test stuff. Go ahead. Can always fix tests later.
(Assignee)

Updated

10 years ago
Status: NEW → RESOLVED
Last Resolved: 10 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.