Click here to Skip to main content
15,890,897 members

Welcome to the Lounge

   

For discussing anything related to a software developer's life but is not for programming questions. Got a programming question?

The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.

 
GeneralRe: RIP Mr Peanut Pin
dandy7224-Jan-20 4:19
dandy7224-Jan-20 4:19 
GeneralRe: RIP Mr Peanut Pin
Jörgen Andersson24-Jan-20 4:22
professionalJörgen Andersson24-Jan-20 4:22 
GeneralRe: RIP Mr Peanut Pin
dandy7224-Jan-20 4:31
dandy7224-Jan-20 4:31 
GeneralRe: RIP Mr Peanut Pin
Jörgen Andersson24-Jan-20 5:02
professionalJörgen Andersson24-Jan-20 5:02 
GeneralRe: RIP Mr Peanut Pin
dandy7224-Jan-20 5:05
dandy7224-Jan-20 5:05 
GeneralRe: RIP Mr Peanut Pin
Jörgen Andersson24-Jan-20 5:04
professionalJörgen Andersson24-Jan-20 5:04 
GeneralRe: RIP Mr Peanut Pin
dandy7224-Jan-20 5:08
dandy7224-Jan-20 5:08 
GeneralI don't know if this has been done but i can find nothing on it Pin
honey the codewitch22-Jan-20 11:04
mvahoney the codewitch22-Jan-20 11:04 
Partial NFA to DFA transformations, opportunistic like so they skip transforming sections of the graph that have too many input values to compare given a reasonable (probably definable) threshold.

This way it short circuits large unicode ranges and keeps those as NFA, while compacting the parts of the graph it can to DFA.

If it hasn't, I may need to produce an article about it but it's for some serious CompSci nerds as opposed to just coders (often not the same thing)

This optimizing compiler I'm writing is turning out to be a chore, but I'm learning a lot.

Update: I forwent the DFA transition so far altogether and simply doing the NFA to code generates tighter code Smile | :)

L0000: save 0
L0001: jmp L0002, L0008, L0017, L0021
L0002: jmp L0003
L0003: switch case "A".."Z", "_", "a".."z":L0004
L0004: switch case "A".."Z", "_", "a".."z", "0".."9":L0005, default:L0005
L0005: jmp L0004, L0006
L0006: save 1
L0007: match 0
L0008: jmp L0009
L0009: jmp L0010, L0011
L0010: switch case "0":L0015
L0011: switch case "-":L0012, default:L0012
L0012: switch case "1".."9":L0013
L0013: switch case "0".."9":L0014, default:L0014
L0014: jmp L0013, L0015
L0015: save 1
L0016: match 1
L0017: jmp L0018
L0018: switch case " ", "\t", "\r", "\n", "\v", "\f":L0019
L0019: save 1
L0020: match 2
L0021: any
L0022: save 1
L0023: match -1

I still need to do things like pass over the code and turn the code at L0018: for example, to a simple "set" instruction
Real programmers use butterflies


modified 22-Jan-20 21:50pm.

GeneralSilly word you have to use in a UI Pin
Gary Wheeler22-Jan-20 7:06
Gary Wheeler22-Jan-20 7:06 
GeneralRe: Silly word you have to use in a UI Pin
honey the codewitch22-Jan-20 7:09
mvahoney the codewitch22-Jan-20 7:09 
GeneralRe: Silly word you have to use in a UI Pin
Gary Wheeler22-Jan-20 7:12
Gary Wheeler22-Jan-20 7:12 
GeneralRe: Silly word you have to use in a UI Pin
honey the codewitch22-Jan-20 7:15
mvahoney the codewitch22-Jan-20 7:15 
GeneralRe: Silly word you have to use in a UI Pin
Gary Wheeler22-Jan-20 7:17
Gary Wheeler22-Jan-20 7:17 
GeneralRe: Silly word you have to use in a UI Pin
SeattleC++23-Jan-20 5:17
SeattleC++23-Jan-20 5:17 
GeneralRe: Silly word you have to use in a UI Pin
Gary Wheeler23-Jan-20 5:27
Gary Wheeler23-Jan-20 5:27 
GeneralRe: Silly word you have to use in a UI Pin
Jane's Diary23-Jan-20 8:08
Jane's Diary23-Jan-20 8:08 
GeneralRe: Silly word you have to use in a UI Pin
Richard Deeming22-Jan-20 7:16
mveRichard Deeming22-Jan-20 7:16 
GeneralOnly silly until you know the meaning... Pin
bVagadishnu22-Jan-20 7:42
bVagadishnu22-Jan-20 7:42 
GeneralRe: Silly word you have to use in a UI Pin
ernieg5422-Jan-20 22:08
professionalernieg5422-Jan-20 22:08 
GeneralRe: Silly word you have to use in a UI Pin
honey the codewitch23-Jan-20 0:27
mvahoney the codewitch23-Jan-20 0:27 
GeneralRe: Silly word you have to use in a UI Pin
kalberts23-Jan-20 1:00
kalberts23-Jan-20 1:00 
GeneralRe: Silly word you have to use in a UI Pin
obermd23-Jan-20 3:03
obermd23-Jan-20 3:03 
GeneralRe: Silly word you have to use in a UI Pin
CoolTeddyBear23-Jan-20 3:29
CoolTeddyBear23-Jan-20 3:29 
GeneralRe: Silly word you have to use in a UI Pin
honey the codewitch23-Jan-20 4:17
mvahoney the codewitch23-Jan-20 4:17 
GeneralRe: Silly word you have to use in a UI Pin
CoolTeddyBear23-Jan-20 5:20
CoolTeddyBear23-Jan-20 5:20 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.