From c88e4e8a0597f833ec468124e21c323335cf8094 Mon Sep 17 00:00:00 2001 From: Richard Brooksby Date: Mon, 20 Feb 2023 08:51:15 +0000 Subject: [PATCH] Downgrading old fixmes to todos with better explanation of tasks. --- mps/code/arenavm.c | 2 +- mps/code/arg.c | 4 +++- mps/code/buffer.c | 3 ++- mps/code/config.h | 2 +- mps/code/prmcxc.h | 4 ++-- mps/code/splay.c | 2 +- mps/code/vmw3.c | 4 +++- mps/example/scheme/scheme-advanced.c | 3 ++- mps/example/scheme/scheme.c | 3 ++- 9 files changed, 17 insertions(+), 10 deletions(-) diff --git a/mps/code/arenavm.c b/mps/code/arenavm.c index fbd523eb965..c3f5efea5fd 100644 --- a/mps/code/arenavm.c +++ b/mps/code/arenavm.c @@ -183,7 +183,7 @@ static Bool VMArenaCheck(VMArena vmArena) CHECKD(Land, VMArenaSpareLand(vmArena)); CHECKL((LandSize)(VMArenaSpareLand(vmArena)) == arena->spareCommitted); - /* FIXME: Can't check VMParams */ + /* TODO: Add sig to VMParamsStruct so it can be checked. */ return TRUE; } diff --git a/mps/code/arg.c b/mps/code/arg.c index a1c74204d48..43fd4c9c415 100644 --- a/mps/code/arg.c +++ b/mps/code/arg.c @@ -65,7 +65,9 @@ Bool ArgCheckPoolDebugOptions(Arg arg) Bool ArgCheckFun(Arg arg) { - CHECKL(FUNCHECK(arg->val.addr_method)); /* FIXME: Potential pun here */ + /* TODO: Fix potential pun here on Harvard architectures where + function pointers are not compatible with other pointers. */ + CHECKL(FUNCHECK(arg->val.addr_method)); return TRUE; } diff --git a/mps/code/buffer.c b/mps/code/buffer.c index ed38f1075bc..5cf0f7ed419 100644 --- a/mps/code/buffer.c +++ b/mps/code/buffer.c @@ -357,7 +357,8 @@ void BufferFinish(Buffer buffer) AVERT(Buffer, buffer); AVER(BufferIsReady(buffer)); - BufferDetach(buffer, BufferPool(buffer)); /* FIXME: Should be in BufferAbsFinish? */ + /* TODO: Consider whether this could move to BufferAbsFinish. */ + BufferDetach(buffer, BufferPool(buffer)); Method(Inst, buffer, finish)(MustBeA(Inst, buffer)); } diff --git a/mps/code/config.h b/mps/code/config.h index 83f985a8859..6ab556c806e 100644 --- a/mps/code/config.h +++ b/mps/code/config.h @@ -393,7 +393,7 @@ /* Pool MVT Configuration -- see */ -/* FIXME: These numbers were lifted from mv2test and need thought. */ +/* TODO: These numbers were lifted from mv2test and need thought. */ #define MVT_ALIGN_DEFAULT MPS_PF_ALIGN #define MVT_MIN_SIZE_DEFAULT MPS_PF_ALIGN diff --git a/mps/code/prmcxc.h b/mps/code/prmcxc.h index be2b6d0a974..ba26393937d 100644 --- a/mps/code/prmcxc.h +++ b/mps/code/prmcxc.h @@ -26,8 +26,8 @@ typedef struct MutatorContextStruct { Addr address; /* Fault address, if stopped by protection * fault; NULL if stopped by thread manager. */ THREAD_STATE_S *threadState; - /* FIXME: Might need to get the floats in case the compiler stashes - intermediate values in them. */ + /* TODO: Consider getting the floats in case the compiler stashes + intermediate values in them. Never observed. */ } MutatorContextStruct; extern void MutatorContextInitFault(MutatorContext context, Addr address, THREAD_STATE_S *threadState); diff --git a/mps/code/splay.c b/mps/code/splay.c index 12682f7dd4b..4831d306353 100644 --- a/mps/code/splay.c +++ b/mps/code/splay.c @@ -1237,7 +1237,7 @@ Bool SplayFindFirst(Tree *nodeReturn, SplayTree splay, while (!found) { Tree oldRoot, newRoot; - /* FIXME: Rename to "seen" and "not yet seen" or something. */ + /* TODO: Rename to "seen" and "not yet seen" or something. */ oldRoot = SplayTreeRoot(splay); newRoot = TreeRight(oldRoot); diff --git a/mps/code/vmw3.c b/mps/code/vmw3.c index 898ca1a77ae..de12e0bd2a9 100644 --- a/mps/code/vmw3.c +++ b/mps/code/vmw3.c @@ -67,6 +67,8 @@ Size PageSize(void) typedef struct VMParamsStruct { + /* TODO: Add sig and check with AVERT in VMInit and CHECKD in + VMArenaCheck. */ Bool topDown; } VMParamsStruct, *VMParams; @@ -101,7 +103,7 @@ Res VMInit(VM vm, Size size, Size grainSize, void *params) AVER(vm != NULL); AVERT(ArenaGrainSize, grainSize); AVER(size > 0); - AVER(params != NULL); /* FIXME: Should have full AVERT? */ + AVER(params != NULL); AVER(COMPATTYPE(LPVOID, Addr)); /* .assume.lpvoid-addr */ AVER(COMPATTYPE(SIZE_T, Size)); diff --git a/mps/example/scheme/scheme-advanced.c b/mps/example/scheme/scheme-advanced.c index 56d2a1bdf62..cdf24590d40 100644 --- a/mps/example/scheme/scheme-advanced.c +++ b/mps/example/scheme/scheme-advanced.c @@ -4505,7 +4505,8 @@ int main(int argc, char *argv[]) } MPS_ARGS_END(args); if (res != MPS_RES_OK) error("Couldn't create obj format"); - /* Create a chain controlling GC strategy. FIXME: explain! */ + /* Create a chain controlling GC strategy. */ + /* TODO: Brief explanation with link to manual. */ res = mps_chain_create(&obj_chain, arena, LENGTH(obj_gen_params), diff --git a/mps/example/scheme/scheme.c b/mps/example/scheme/scheme.c index 7ffeb7c8ef4..c5f088a312d 100644 --- a/mps/example/scheme/scheme.c +++ b/mps/example/scheme/scheme.c @@ -4442,7 +4442,8 @@ int main(int argc, char *argv[]) } MPS_ARGS_END(args); if (res != MPS_RES_OK) error("Couldn't create obj format"); - /* Create a chain controlling GC strategy. FIXME: explain! */ + /* Create a chain controlling GC strategy. */ + /* TODO: Brief explanation with link to manual. */ res = mps_chain_create(&obj_chain, arena, LENGTH(obj_gen_params),