id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 3513,regex_match very slow example,Fernando Pelliccioni ,Eric Niebler,"Hi, I am having an issue with a dynamic regular expresion. I have this source code. sregex tempRE = sregex::compile(""^(?:.*\\r?\\n)*var wlanPara = new Array\\(\\r?\\n\\d{0,4},\\r?\\n\""(?P(?:\\w+))\"",\\r?\\n(?P(?:\\d{0,4})),\\r?\\n\\d{0,4},\\r?\\n\""[\\w-]+\"",\\r?\\n\""[\\w\\.]+\"",\\r?\\n\\d{0,4},\\r?\\n\\d{0,4},\\r?\\n\""(?P(?:\\d{0,4})) dB\"",\\r?\\n\\d{0,4},\\d{0,4} \\);(?:.*\\r?\\n)*$""); std::string htmlText; // filled using text in html file attached smatch what; if(regex_match(htmlText, what, tempRE)) { //... } When the program enters to the regex_match function, the process consumes 50% of the processor and the function never returns. I was attach the html file that contains the text. The source code was tested using VisualStudio 2008. If I use the static variant of regex, it's works perfectly.. sregex tempRE = bos >> *_ >> ""var wlanPara = new Array("" >> _ln >> _d >> commonDigit >> ',' >> _ln >> '""' >> (s1= +_w) >> ""\"","" >> _ln >> (s2= commonDigit) >> ',' >> _ln >> commonDigit >> ',' >> _ln >> '""' >> +(_w | '-') >> ""\"","" >> _ln >> '""' >> +(_w | '.') >> ""\"","" >> _ln >> commonDigit >> ',' >> _ln >> commonDigit >> ',' >> _ln >> '""' >> (s3= commonDigit) >> "" dB\"","" >> _ln >> commonDigit >> ',' >> commonDigit >> "" );"" >> *_ >> eos; Thanks, Fernando Pelliccioni",Support Requests,closed,Boost 1.41.0,xpressive,Boost 1.40.0,Problem,invalid,,