Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make transforms part of the public MPS #214

Merged
merged 24 commits into from
Jun 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
b745b69
Part of making transforms part of the public MPS.
rptb1 Apr 14, 2023
72f0d63
Make transforms part of the public MPS.
gareth-rees Jan 23, 2022
3ad9c5f
Fixing type puns found by GCC 11.3.0.
rptb1 Jun 12, 2023
5b9f759
Removing custom CET section (containing only transforms) from the man…
rptb1 Jun 12, 2023
08aaf46
Fixing typo in Sphinx directive.
rptb1 Jun 12, 2023
a7ebcbd
Catch-up merge of master into branch/2023-04-13/transforms to resolve…
rptb1 Jun 12, 2023
380fbf5
Avoid creating ambiguous references in stack slots that prevent the t…
rptb1 Jun 12, 2023
9f71e31
Temporarily disabling ztfm test except on Windows because GCC (in par…
rptb1 Jun 14, 2023
cec1509
Suppressing "may be used uninitialized" warning in rash build with GC…
rptb1 Jun 14, 2023
b0cca65
add FIXMEs to ztfm.c testbench after walkthrough with RB
thejayps Jun 15, 2023
521e664
Converting FIXMEs to comments containing what we have deduced about t…
rptb1 Jun 16, 2023
ebe0af1
Moving transforms design statements out of leader comment of trans.c,…
rptb1 Jun 16, 2023
3b97736
Clarifying comments on TableCreate in response to review <https://git…
rptb1 Jun 16, 2023
0c3b0af
Removing statements that are no longer true or are rendered untrue by…
rptb1 Jun 16, 2023
d74a0df
Removing mpsitr.c, a relic of custom/cet, and merging its contents in…
rptb1 Jun 16, 2023
dc6feb3
Adding spaces to conform to rule.code.style.control.
rptb1 Jun 16, 2023
54e34ed
Marking up list of causes as a list, for clarity, in response to revi…
rptb1 Jun 16, 2023
0eeefad
Clarifying relationship between mps_pool_walk and transforms with bri…
rptb1 Jun 16, 2023
d769826
Transforms are no longer implicitly destroyed by applying them, makin…
rptb1 Jun 16, 2023
38b7812
Clarifying why and documenting that transformed references must be in…
rptb1 Jun 16, 2023
6663459
Enforcing parking restrictions when adding references to transforms i…
rptb1 Jun 16, 2023
0b27a6c
Removing bogus test block introduced in d769826cc that does not work …
rptb1 Jun 16, 2023
24417c2
Adding design.mps.transform to design index.
rptb1 Jun 16, 2023
8b169cf
remove ambiguity and add clarity about the set of reasons that a tran…
thejayps Jun 17, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion code/comm.gmk
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,7 @@ MPMCOMMON = \
trace.c \
traceanc.c \
tract.c \
trans.c \
tree.c \
version.c \
vm.c \
Expand Down Expand Up @@ -294,7 +295,8 @@ TEST_TARGETS=\
teletest \
walkt0 \
zcoll \
zmess
zmess \
ztfm

# This target records programs that we were once able to build but
# can't at the moment:
Expand Down Expand Up @@ -572,6 +574,9 @@ $(PFM)/$(VARIETY)/zcoll: $(PFM)/$(VARIETY)/zcoll.o \
$(PFM)/$(VARIETY)/zmess: $(PFM)/$(VARIETY)/zmess.o \
$(FMTDYTSTOBJ) $(TESTLIBOBJ) $(PFM)/$(VARIETY)/mps.a

$(PFM)/$(VARIETY)/ztfm: $(PFM)/$(VARIETY)/ztfm.o \
$(FMTDYTSTOBJ) $(TESTLIBOBJ) $(PFM)/$(VARIETY)/mps.a

$(PFM)/$(VARIETY)/mpseventcnv: $(PFM)/$(VARIETY)/eventcnv.o \
$(PFM)/$(VARIETY)/mps.a

Expand Down
3 changes: 0 additions & 3 deletions code/commpost.nmk
Original file line number Diff line number Diff line change
Expand Up @@ -219,9 +219,6 @@ $(PFM)\$(VARIETY)\btcv.exe: $(PFM)\$(VARIETY)\btcv.obj \
$(PFM)\$(VARIETY)\bttest.exe: $(PFM)\$(VARIETY)\bttest.obj \
$(PFM)\$(VARIETY)\mps.lib $(TESTLIBOBJ)

$(PFM)\$(VARIETY)\cvmicv.exe: $(PFM)\$(VARIETY)\cvmicv.obj \
$(PFM)\$(VARIETY)\mps.lib $(FMTTESTOBJ) $(TESTLIBOBJ)

$(PFM)\$(VARIETY)\djbench.exe: $(PFM)\$(VARIETY)\djbench.obj \
$(TESTLIBOBJ) $(TESTTHROBJ)

Expand Down
4 changes: 3 additions & 1 deletion code/commpre.nmk
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,8 @@ TEST_TARGETS=\
teletest.exe \
walkt0.exe \
zcoll.exe \
zmess.exe
zmess.exe \
ztfm.exe

# Stand-alone programs go in EXTRA_TARGETS if they should always be
# built, or in OPTIONAL_TARGETS if they should only be built if
Expand Down Expand Up @@ -170,6 +171,7 @@ MPMCOMMON=\
[trace] \
[traceanc] \
[tract] \
[trans] \
[tree] \
[version] \
[vm] \
Expand Down
1 change: 1 addition & 0 deletions code/mps.c
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@
#include "failover.c"
#include "vm.c"
#include "policy.c"
#include "trans.c"

/* Additional pool classes */

Expand Down
9 changes: 9 additions & 0 deletions code/mps.h
Original file line number Diff line number Diff line change
Expand Up @@ -846,6 +846,15 @@ extern mps_res_t _mps_fix2(mps_ss_t, mps_addr_t *);
MPS_END


/* Transforms interface. */

typedef struct mps_transform_s *mps_transform_t;
extern mps_res_t mps_transform_create(mps_transform_t *, mps_arena_t);
extern mps_res_t mps_transform_add_oldnew(mps_transform_t, mps_addr_t *, mps_addr_t *, size_t);
extern mps_res_t mps_transform_apply(mps_bool_t *, mps_transform_t);
extern void mps_transform_destroy(mps_transform_t);


#endif /* mps_h */


Expand Down
124 changes: 124 additions & 0 deletions code/mps.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@
3114A6B9156E9763001E0AA3 /* PBXTargetDependency */,
31D60063156D3F5C00337B26 /* PBXTargetDependency */,
31D60087156D3FE600337B26 /* PBXTargetDependency */,
220FD3F419533E8F00967A35 /* PBXTargetDependency */,
3114A6D5156E9839001E0AA3 /* PBXTargetDependency */,
2265D72220E54020003019E8 /* PBXTargetDependency */,
2D07B9791636FCBD00DB751B /* PBXTargetDependency */,
Expand All @@ -131,6 +132,13 @@
/* End PBXAggregateTarget section */

/* Begin PBXBuildFile section */
220FD3DD195339C000967A35 /* fmtdy.c in Sources */ = {isa = PBXBuildFile; fileRef = 3124CAC6156BE48D00753214 /* fmtdy.c */; };
220FD3DE195339C000967A35 /* fmtdytst.c in Sources */ = {isa = PBXBuildFile; fileRef = 3124CAC7156BE48D00753214 /* fmtdytst.c */; };
220FD3DF195339C000967A35 /* fmthe.c in Sources */ = {isa = PBXBuildFile; fileRef = 3124CAE4156BE6D500753214 /* fmthe.c */; };
220FD3E1195339C000967A35 /* testlib.c in Sources */ = {isa = PBXBuildFile; fileRef = 31EEAC9E156AB73400714D05 /* testlib.c */; };
220FD3E3195339C000967A35 /* libmps.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 31EEABFB156AAF9D00714D05 /* libmps.a */; };
220FD3F119533E7200967A35 /* fmtno.c in Sources */ = {isa = PBXBuildFile; fileRef = 3124CACC156BE4C200753214 /* fmtno.c */; };
220FD3F219533E7900967A35 /* ztfm.c in Sources */ = {isa = PBXBuildFile; fileRef = 220FD3F019533C3200967A35 /* ztfm.c */; };
2215A9C9192A495F00E9E2CE /* pooln.c in Sources */ = {isa = PBXBuildFile; fileRef = 22FACEDE18880933000FDBC1 /* pooln.c */; };
2231BB5118CA97D8002D6322 /* testlib.c in Sources */ = {isa = PBXBuildFile; fileRef = 31EEAC9E156AB73400714D05 /* testlib.c */; };
2231BB5318CA97D8002D6322 /* libmps.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 31EEABFB156AAF9D00714D05 /* libmps.a */; };
Expand Down Expand Up @@ -349,6 +357,20 @@
/* End PBXBuildFile section */

/* Begin PBXContainerItemProxy section */
220FD3DA195339C000967A35 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 31EEABDA156AAE9E00714D05 /* Project object */;
proxyType = 1;
remoteGlobalIDString = 31EEABFA156AAF9D00714D05;
remoteInfo = mps;
};
220FD3F319533E8F00967A35 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 31EEABDA156AAE9E00714D05 /* Project object */;
proxyType = 1;
remoteGlobalIDString = 220FD3D8195339C000967A35;
remoteInfo = ztfm;
};
2215A9AB192A47BB00E9E2CE /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 31EEABDA156AAE9E00714D05 /* Project object */;
Expand Down Expand Up @@ -1038,6 +1060,15 @@
/* End PBXContainerItemProxy section */

/* Begin PBXCopyFilesBuildPhase section */
220FD3E4195339C000967A35 /* CopyFiles */ = {
isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647;
dstPath = /usr/share/man/man1/;
dstSubfolderSpec = 0;
files = (
);
runOnlyForDeploymentPostprocessing = 1;
};
2231BB5418CA97D8002D6322 /* CopyFiles */ = {
isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647;
Expand Down Expand Up @@ -1493,6 +1524,12 @@
/* Begin PBXFileReference section */
2213454C1DB0386600E14202 /* prmc.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = prmc.h; sourceTree = "<group>"; };
2213454D1DB038D400E14202 /* prmcxc.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = prmcxc.c; sourceTree = "<group>"; };
220FD3E9195339C000967A35 /* ztfm */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = ztfm; sourceTree = BUILT_PRODUCTS_DIR; };
220FD3EA195339E500967A35 /* mpsitr.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = mpsitr.c; sourceTree = "<group>"; };
220FD3EB195339F000967A35 /* trans.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = trans.c; sourceTree = "<group>"; };
220FD3ED19533A8700967A35 /* mpscvm.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = mpscvm.h; sourceTree = "<group>"; };
220FD3EE19533A8700967A35 /* trans.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = trans.h; sourceTree = "<group>"; };
220FD3F019533C3200967A35 /* ztfm.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = ztfm.c; sourceTree = "<group>"; };
2231BB5918CA97D8002D6322 /* locbwcss */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = locbwcss; sourceTree = BUILT_PRODUCTS_DIR; };
2231BB6718CA97DC002D6322 /* locusss */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = locusss; sourceTree = BUILT_PRODUCTS_DIR; };
2231BB6818CA9834002D6322 /* locbwcss.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = locbwcss.c; sourceTree = "<group>"; };
Expand Down Expand Up @@ -1808,6 +1845,14 @@
/* End PBXFileReference section */

/* Begin PBXFrameworksBuildPhase section */
220FD3E2195339C000967A35 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
220FD3E3195339C000967A35 /* libmps.a in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
2231BB5218CA97D8002D6322 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
Expand Down Expand Up @@ -2394,6 +2439,7 @@
3114A6BA156E9768001E0AA3 /* walkt0.c */,
31D6005E156D3F4A00337B26 /* zcoll.c */,
31D6007B156D3FCC00337B26 /* zmess.c */,
220FD3F019533C3200967A35 /* ztfm.c */,
);
name = Tests;
sourceTree = "<group>";
Expand Down Expand Up @@ -2485,6 +2531,7 @@
223E796519EAB00B00DC26A6 /* sncss */,
22EA3F4520D2B0D90065F5B6 /* forktest */,
2265D71D20E53F9C003019E8 /* mpseventpy */,
220FD3E9195339C000967A35 /* ztfm */,
);
name = Products;
sourceTree = "<group>";
Expand Down Expand Up @@ -2539,7 +2586,9 @@
311F2F6517398B3B00C15B6A /* mpsacl.h */,
311F2F6617398B3B00C15B6A /* mpsavm.h */,
22FACEDB188808D5000FDBC1 /* mpscmfs.h */,
220FD3ED19533A8700967A35 /* mpscvm.h */,
31EEABF5156AAF7C00714D05 /* mpsi.c */,
220FD3EA195339E500967A35 /* mpsitr.c */,
311F2F6717398B3B00C15B6A /* mpsio.h */,
311F2F6817398B3B00C15B6A /* mpslib.h */,
311F2F6917398B3B00C15B6A /* mpstd.h */,
Expand Down Expand Up @@ -2583,6 +2632,8 @@
31EEAC1F156AB2B200714D05 /* traceanc.c */,
31EEAC0D156AB27B00714D05 /* tract.c */,
311F2F7A17398B8E00C15B6A /* tract.h */,
220FD3EB195339F000967A35 /* trans.c */,
220FD3EE19533A8700967A35 /* trans.h */,
310F5D7118B6675F007EFCBC /* tree.c */,
310F5D7218B6675F007EFCBC /* tree.h */,
31EEAC44156AB32500714D05 /* version.c */,
Expand Down Expand Up @@ -2667,6 +2718,24 @@
/* End PBXHeadersBuildPhase section */

/* Begin PBXNativeTarget section */
220FD3D8195339C000967A35 /* ztfm */ = {
isa = PBXNativeTarget;
buildConfigurationList = 220FD3E5195339C000967A35 /* Build configuration list for PBXNativeTarget "ztfm" */;
buildPhases = (
220FD3DB195339C000967A35 /* Sources */,
220FD3E2195339C000967A35 /* Frameworks */,
220FD3E4195339C000967A35 /* CopyFiles */,
);
buildRules = (
);
dependencies = (
220FD3D9195339C000967A35 /* PBXTargetDependency */,
);
name = ztfm;
productName = zmess;
productReference = 220FD3E9195339C000967A35 /* ztfm */;
productType = "com.apple.product-type.tool";
};
2231BB4C18CA97D8002D6322 /* locbwcss */ = {
isa = PBXNativeTarget;
buildConfigurationList = 2231BB5518CA97D8002D6322 /* Build configuration list for PBXNativeTarget "locbwcss" */;
Expand Down Expand Up @@ -3610,6 +3679,7 @@
3114A6AB156E9759001E0AA3 /* walkt0 */,
31D60053156D3F3500337B26 /* zcoll */,
31D60070156D3FBC00337B26 /* zmess */,
220FD3D8195339C000967A35 /* ztfm */,
3114A6C5156E9815001E0AA3 /* mpseventcnv */,
2265D71120E53F9C003019E8 /* mpseventpy */,
2D07B9701636FC9900DB751B /* mpseventsql */,
Expand Down Expand Up @@ -3695,6 +3765,19 @@
/* End PBXShellScriptBuildPhase section */

/* Begin PBXSourcesBuildPhase section */
220FD3DB195339C000967A35 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
220FD3F219533E7900967A35 /* ztfm.c in Sources */,
220FD3DD195339C000967A35 /* fmtdy.c in Sources */,
220FD3DE195339C000967A35 /* fmtdytst.c in Sources */,
220FD3DF195339C000967A35 /* fmthe.c in Sources */,
220FD3F119533E7200967A35 /* fmtno.c in Sources */,
220FD3E1195339C000967A35 /* testlib.c in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
2231BB4F18CA97D8002D6322 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
Expand Down Expand Up @@ -4202,6 +4285,16 @@
/* End PBXSourcesBuildPhase section */

/* Begin PBXTargetDependency section */
220FD3D9195339C000967A35 /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = 31EEABFA156AAF9D00714D05 /* mps */;
targetProxy = 220FD3DA195339C000967A35 /* PBXContainerItemProxy */;
};
220FD3F419533E8F00967A35 /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = 220FD3D8195339C000967A35 /* ztfm */;
targetProxy = 220FD3F319533E8F00967A35 /* PBXContainerItemProxy */;
};
2215A9AA192A47BB00E9E2CE /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = 3104AFF1156D37A0000A585A /* all */;
Expand Down Expand Up @@ -4695,6 +4788,27 @@
/* End PBXTargetDependency section */

/* Begin XCBuildConfiguration section */
220FD3E6195339C000967A35 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
PRODUCT_NAME = "$(TARGET_NAME)";
};
name = Debug;
};
220FD3E7195339C000967A35 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
PRODUCT_NAME = "$(TARGET_NAME)";
};
name = Release;
};
220FD3E8195339C000967A35 /* RASH */ = {
isa = XCBuildConfiguration;
buildSettings = {
PRODUCT_NAME = "$(TARGET_NAME)";
};
name = RASH;
};
2215A9AE192A47BB00E9E2CE /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
Expand Down Expand Up @@ -6103,6 +6217,16 @@
/* End XCBuildConfiguration section */

/* Begin XCConfigurationList section */
220FD3E5195339C000967A35 /* Build configuration list for PBXNativeTarget "ztfm" */ = {
isa = XCConfigurationList;
buildConfigurations = (
220FD3E6195339C000967A35 /* Debug */,
220FD3E7195339C000967A35 /* Release */,
220FD3E8195339C000967A35 /* RASH */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
2215A9AD192A47BB00E9E2CE /* Build configuration list for PBXAggregateTarget "testci" */ = {
isa = XCConfigurationList;
buildConfigurations = (
Expand Down
Loading