Skip to content

Commit

Permalink
account for files generated by -save-temps; minor updates to readme
Browse files Browse the repository at this point in the history
  • Loading branch information
ixfd64 committed Mar 4, 2025
1 parent 18e2548 commit e092184
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 11 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@
src/*.tmp
src/depend

# generated by -save-temps
*.i
*.ii

# binaries
mfakto
*.elf
Expand Down
16 changes: 8 additions & 8 deletions README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@ Contents
7 Plans


#####################
# 0 What is mfakto? #
#####################
##################
# 0 About mfakto #
##################

mfakto is an OpenCL port of mfaktc that aims to have the same features and
functions. mfaktc is a program that trial factors Mersenne numbers. It stands
Expand Down Expand Up @@ -401,12 +401,12 @@ Submitting results:

- mfakto can find factors outside the given range.
This is because mfakto works on huge factor blocks, controlled by GridSize in
the INI file. The default value GridSize=3 means mfakto runs up to 1048576
the INI file. The default value of GridSize=3 means mfakto runs up to 1048576
factor candidates at once, per class. So the last block of each class is
filled with factor candidates above the upper limit. This is a huge overhead
for small ranges but can be safely ignored for larger ranges. For example,
the average overhead is 0.5% for a class with 100 blocks but only 0.05% for
one with 1000 blocks.
filled up with factor candidates to above the upper bit level. This is a huge
overhead for small ranges but can be safely ignored for larger ranges.
For example, the average overhead is 0.5% for a class with 100 blocks but
only 0.05% for one with 1000 blocks.

############
# 5 Tuning #
Expand Down
10 changes: 7 additions & 3 deletions src/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ all: $(ALL_TARGETS)
$(LD) $^ $(LDFLAGS) -o $@

clean:
$(RM) *.o *~ depend
$(RM) *.o *~ depend *.i *.ii

sieve.o : sieve.c
$(CC) $(CFLAGS) $(CFLAGS_EXTRA_SIEVE) -c $< -o $@
Expand Down Expand Up @@ -141,9 +141,13 @@ depend: $(CSRC)
mv $@.tmp $@

ifdef MAKECMDGOALS
ifneq ($(MAKECMDGOALS), clean)
goals := $(MAKECMDGOALS)
else
goals := all
endif

ifneq ($(goals), clean)
ifneq (, $(wildcard depend))
include depend
endif
endif
endif

0 comments on commit e092184

Please sign in to comment.